You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Webpack has a feature that allows deciding at runtime what host to use for loading build files.
The API to do it is a bit odd and requires setting a seemingly magic variable (__webpack_public_path__) at the very beginning of your entry point file. Since embroider controls the entry point file handed to webpack behind the scenes, there's currently no way to accomplish this.
In practice, this feature allows you to do something like
and now your server can control what CDN is used at runtime by including that meta tag in the html.
In my case I am uploading the same build assets to multiple CDNs and would like the ability to dynamically decide between them. My ember build takes ~30 minutes in CI so running the build multiple times just to be able to switch CDN is not feasible for me.
The text was updated successfully, but these errors were encountered:
Webpack has a feature that allows deciding at runtime what host to use for loading build files.
The API to do it is a bit odd and requires setting a seemingly magic variable (
__webpack_public_path__
) at the very beginning of your entry point file. Since embroider controls the entry point file handed to webpack behind the scenes, there's currently no way to accomplish this.In practice, this feature allows you to do something like
and now your server can control what CDN is used at runtime by including that meta tag in the html.
In my case I am uploading the same build assets to multiple CDNs and would like the ability to dynamically decide between them. My ember build takes ~30 minutes in CI so running the build multiple times just to be able to switch CDN is not feasible for me.
The text was updated successfully, but these errors were encountered: