Open arjansingh opened 7 years ago
Also just hit this issue. This happens when ember-fetch
is a dependency and not a dev dependency in package.json
. It works just fine if you move it to devDependencies
.
The issue here is that the asset manifest is generated by crawling the directory structure at the end of the build. Thus any files in the crawled directories get added to the manifest. We recently landed a change to ember-asset-loader to allow files to be ignored, but the API is not currently exposed in ember-engines.
This issue was created before Fastboot support. I think that this can be closed.
cc: @rwjblue
@villander any chance you can reopen this? This issue is still active. Ran into it with the latest of ember-fetch and ember-engines.
@trentmwillis's API for allowing engines to exclude files from the manifest would resolve this.
Happy to carry the torch if anyone wants to pass along some context before I get started. My assumption is this config should be read from the engine config. Since there isn't really a build time app.options
objects in the context of an engine, we would need to come to a consensus on that first. Perhaps we hang off the addon/engine object and the host app, the one generating the manifest, would merge all the engine options together.
@jasonmit - Maybe we can start with a small repro? (Mostly to make sure I grok the current issue that you mentioned in ember-cli/ember-fetch#69...)
@rwjblue here is an example of the issue: https://github.com/jasonmit/x-lazy-app/
Summary
The
asset-manifest.json
generated by Ember Engines is asking the browser to fetch Fastboot- specific build code. This code should be filtered out by the Engine build process but its not.It occurs in any engine that is mounted in an application that contains
ember-cli-fastboot
, regardless of whether that host application is being Fastbooted or not.The main discussion/discovery of this happened on: https://github.com/ember-cli/ember-fetch/pull/70
Reproduction steps and sample Ember App that duplicates this behavior is here: https://github.com/arjansingh/ember-bugs/pull/1
Any thoughts on a potential fix?
// CC @kratiahuja