Skip to content
This repository has been archived by the owner on Apr 17, 2020. It is now read-only.

Ember serve fails if the appname doesn't contain a dash #15

Closed
t-sauer opened this issue Mar 28, 2017 · 3 comments
Closed

Ember serve fails if the appname doesn't contain a dash #15

t-sauer opened this issue Mar 28, 2017 · 3 comments
Labels

Comments

@t-sauer
Copy link
Contributor

t-sauer commented Mar 28, 2017

Steps to reproduce:

  1. ember new playground -b @glimmer/blueprint
  2. cd playground
  3. ember serve

The following error shows up:

Livereload server on http://localhost:49154
Serving on http://localhost:4200/
The Broccoli Plugin: [ResolutionMapBuilder] failed with:
Error: The collection 'components' is not configured to contain a collection 'playground'
    at /Users/ts02/Code/glimmer/playground/node_modules/@glimmer/resolution-map-builder/lib/get-module-specifier.js:44:17
    at Array.forEach (native)
    at module.exports.moduleExtension (/Users/ts02/Code/glimmer/playground/node_modules/@glimmer/resolution-map-builder/lib/get-module-specifier.js:39:11)
    at /Users/ts02/Code/glimmer/playground/node_modules/@glimmer/resolution-map-builder/index.js:66:21
    at Array.forEach (native)
    at ResolutionMapBuilder.build (/Users/ts02/Code/glimmer/playground/node_modules/@glimmer/resolution-map-builder/index.js:63:15)
    at /Users/ts02/Code/glimmer/playground/node_modules/broccoli-plugin/read_compat.js:93:34
    at tryCatch (/Users/ts02/Code/glimmer/playground/node_modules/rsvp/dist/rsvp.js:539:12)
    at invokeCallback (/Users/ts02/Code/glimmer/playground/node_modules/rsvp/dist/rsvp.js:554:13)
    at publish (/Users/ts02/Code/glimmer/playground/node_modules/rsvp/dist/rsvp.js:522:7)

When I repeat the same steps as above with a dash in the name (e.g. play-ground), ember serve works fine.

@t-sauer t-sauer changed the title Ember serve fails if name doesn't contain a dash Ember serve fails if the appname doesn't contain a dash Mar 28, 2017
@mike-north
Copy link

mike-north commented Mar 29, 2017

Workaround:

You'll find that there's a prepended dash for your top-level component in the
src/ui/components folder. Remove this leading dash in the folder name, and in the call to app.renderComponent in src/index.js and you should be good to go.


update
It seems that having a dash in component names may be mandatory. That being said, the fix I mentioned above seems to work (perhaps by happenstance).

@michalsnik
Copy link

It could also be fixed on blueprint level. When the app's name doesn't contain a dash, it could add -app suffix to component name and leave the rest as is. It's only a proposition though.

@locks locks added the bug label Mar 30, 2017
@rwjblue
Copy link
Member

rwjblue commented Apr 1, 2017

Yes, we discussed this a bit yesterday. I believe the consensus was to add -app suffix as mentioned by @michalsnik.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

5 participants