Template not found
hfournier opened this issue · comments
I've got the base setup as Visual Studio project under Windows 10. No errors generated when running meteor, but going to http://localhost:3000/ just shows "Loading...". After looking at the code in VS, I found that in app.component.ts, the following line:
import template from './app.component.html';
appears with a red-squiggle under the string and hovering over it shows: "Cannot find module", which I don't understand because I can clearly see that the file is there.
@hfournier make sure your meteor package angular-compilers
is up-to-date (Currently @ 0.6.1
) and install the typings
typings install github:meteor-typings/angular2-compilers#c2ca3d3036b08f04a22b98ed16ff17377499e1e7 --global
See angular2-meteor's Static Resources.
Thanks @derek-fong . I deleted the whole thing and started over and got the app running now and I'm no longer stuck on the Loading page. However, I'm still getting the red squiggles in VS.
I don't see an angular-compilers, but I'm guessing you meant angular2-compilers? Mine is currently 0.6.0, so I executed:
meteor update angular2-compilers
and got:
While checking for angular2-compilers@0.6.1:
error: No compatible binary build found for this package. Contact the package author and ask them to publish it for your platform.
I'm on Windows 10 using Visual Studio Pro 2015 Update 3.
Sorry about the typo it was angular2-compilers
. :(
If your development machine is a Windows platform then you might want to read this Urigo/angular2-meteor#372
Looks like currently there are some issues with the latest angular2-compilers@0.6.1
with Windows platforms and the workaround is to use 0.6.0
by running
meteor add angular2-compilers@=0.6.0
until the angular2-meteor team has solve this problem.
You might also want to try
meteor add barbatus:typescript@0.4.0
typings install github:meteor-typings/angular2-compilers#c2ca3d3036b08f04a22b98ed16ff17377499e1e7 --global
and see if it can get rid of the red squiggles in VS - This package was included in angular2-compilers
but angular2-compilers@=0.6.0
is still using a 0.3.x version
which is not based on typescript@2.0.0
(See Urigo/angular2-meteor#352)
meteor install barbatus:typescript@0.4.0 'install' is not a Meteor command.
meteor add barbatus:typescript@0.4.0
OK, thanks, that worked, but didn't help with VS issue.
Also got this notification:
Update available 1.3.3 → 1.4.0 Run npm i -g typings to update
Do I want to update or stick with current version?
@hfournier that's a prompt for updating typings
For the VS issue I am not sure why it did not work - i am using other IDEs and the steps I mentioned above worked for me.
Please update to latest TypeScript (> 2) and try again, it should solve the template issue.