Open SuperManHa opened 5 years ago
You also need to add the engine to the consuming app in app/app.js
so the app knows about the engine. IMO this isn't covered very well in the guides, should probably be in the "mounting an engine" section.
You also need to add the engine to the consuming app in
app/app.js
so the app knows about the engine. IMO this isn't covered very well in the guides, should probably be in the "mounting an engine" section.
Thanks for your reply. But I have put it in my app.js
, it's my mistake that I forget this in the issue description. Have update the issue description.
@SuperManHa the ember-engines 0.6.x
is compatible with ember-cli 2.18 or bigger - https://github.com/ember-engines/ember-engines/blob/master/config/ember-try.js#L15
please update ember-cli on your consuming app and try again
thanks!
Is this still an issue?
i try to mount an engine to my project as per the demo: consuming app: https://github.com/dgeb/ember-engines-demo engine app: https://github.com/dgeb/ember-blog-engine
the demo works well. But when i mount the ember-blog-engine to my own consuming app, error occurs and the error message is "Error: Could not find module
ember-blog-engine/engine
imported from(require)
".how i add the engine:
package.json
router.js
this.mount('ember-blog-engine', {as: 'blog'});
I add active-session.js and blog-data.js in services folder because those service is used by the demo engine.
app/app.js
I found the ember-blog-engine's source code is never built into vendor.js, when exec
ember build
, the console shows the engine is in dead module.