-
Notifications
You must be signed in to change notification settings - Fork 519
Unable to start project after generating with Yeo #645
Comments
Have you removed angular2-template-loader from webpack or your installs? It's definitely something about that that's causing it. In general, to use templateUrl or styleUrls you must use angular2-template-loader in your TypeScript loaders. Take a look at my comment here: |
Sorry if I'm coming off as clueless. I'm very new to this process. I haven't removed anything at all from the generated project. Your comment is what I found when googling.
If I do as the comment suggests: templateUrl: to template:require('') it works but am I supposed to do that for all files now or is a change coming? Or should I be doing what waterfoul suggested in that post? Is there anything else I could do to help? I've also tried your other git repo (ang2univ) and seem to be having the same issue. |
I can confirm that I am see the same behavior/error when generating a new project via
Error:
|
Ok now I'm more confused. It was only files that do not have a styleUrls property on the component. If I add one then the file/component is found. Not sure if that helps any. It helps me at the moment since my issue is fixed by adding a bunch of blank css files and styleUrls properties to these components. |
It might be a bug in a recent update that was made to angular2-template-loader or something like that, especially if it's out of no where. It might be looking for them and trying to get the files (when you never even put down a filename) like you were just saying @sutherlandm2 |
I think it is related to this. #TheLarkInn/angular2-template-loader#50 Changed to reflect correct issue. |
There it is! Hopefully Sean will patch it soon. |
None of these methods worked for me. I have angular2-template-loader locked to 0.6.0. If I replace templateUrl: with template: it will load the project but on all three pages I see: "./home.component.html" "./fetchdata.component.html" "./counter.component.html"
|
To solve this i did the following
to |
I can make a change on the template repo to reflect this fix. |
To clarify what worked for me, I had to BOTH lock the version of the template loader and replace the templateUrl with template: require... - FYI I did this with the experimental yo that installs angular 2.4.5 |
This is still happening for me with angular 2.0.2
|
After working with variations of versions for about 2 hours, I was finally able to get the latest 2.4.5 template to work with angular v2.4.6. I think it was angular2-template-loader getting updated to 0.6.1 (2/5/2016), but reverting it alone didn't solve all my problems, so I finally went with this: Note: I stripped out the ^. "dependencies": { |
There are solutions here. |
Locking to "angular2-template-loader": "0.6.0" was enough, just had to manually rebuild the webpack. |
Thanks for the report. This is also tracked in #649, so I'll mark this one as closed. |
I had been using this template for some time and suddenly my project is unable to locate any components. Stating 404 GETs on all componentname.html files.
I attempted to start a fresh project with no changes made to see if I did something wrong.
Generated an angular 2.0.2 project that was not the experimental one.
Did dotnet run and the application will start and the API will work but the client UI will fail with the following:
Thank you for any help.
The text was updated successfully, but these errors were encountered: