Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle lack of app/templates/head.hbs more gracefully. #7

Closed
rwjblue opened this issue May 31, 2016 · 3 comments
Closed

Handle lack of app/templates/head.hbs more gracefully. #7

rwjblue opened this issue May 31, 2016 · 3 comments

Comments

@rwjblue
Copy link
Member

rwjblue commented May 31, 2016

Currently, if you don't have the app/templates/head.hbs file present you get a very difficult to parse error like the following:

Uncaught Error: Could not find module `web-client/templates/head` imported from `web-client/components/head-content

It is pretty hard to track down unless you happen to know what ember-cli-head is doing internally. I think erroring hard is ok here, but it is also possible for us to default to an empty template (to prevent errors like this).

@ronco
Copy link
Collaborator

ronco commented Jun 8, 2016

@rwjblue (Sorry for the late reply.) Is the blueprint that creates one on install insufficient? Was it manually removed? Seems pretty straight forward to add in, just curious how it came up.

@openhouse
Copy link

@ronco I got this error when migrating to pods. I moved web-client/templates/head.hbs in a batch with all my other files and it ended up in web-client/pods/head/template.hbs. I saw the error, moved it back and now it's the only file in my templates directory.

I know 'pods are dead' as we wait for the new module layout. But I thought using pods for the ui files was a good incremental step in my project.

loader.js:212Uncaught Error: Could not find module `web-client/templates/head` imported from `web-client/components/head-content`

ronco added a commit that referenced this issue Jun 14, 2016
So we don't hard error if a consuming app misplaced their head.hbs

Resolves #7
@ronco ronco closed this as completed in #9 Jun 14, 2016
@ronco
Copy link
Collaborator

ronco commented Jun 14, 2016

Included a default template in v0.1.0 release.

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

No branches or pull requests

3 participants