-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Closed
Description
Bug report
What is the current behavior?
Here's an reproduction: https://stackblitz.com/edit/webpack-webpack-js-org-k3ddnttj
Seems like webpack fails to load dynamic imports from nested bundles if they point to a dynamic path (custom public path, or a CDN for example)
If the current behavior is a bug, please provide the steps to reproduce.
run:
npm run build- it'll build two separate bundles:
- one for an ES library that has a dynamic import for a chunk that will be served in
localhost:9010 - one for the app itself, the app will consume the ES library called
entryand aliased to point to the generated ES library bundle
- one for an ES library that has a dynamic import for a chunk that will be served in
- it'll build two separate bundles:
npm start- it'll start two servers concurrently, one serving the distribution folder on port 5000 and another serving just the chunks to be consumed by the ES library on port 9010- access application on localhost:5000 and this error will be on the console:

What is the expected behavior?
Webpack application should consume dynamic import pointing to dynamic paths properly
Other relevant information:
webpack version: 5.99.7
Node.js version:
Operating System:
Additional tools:
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels