These red squiggly lines say cannot find module \'angular2/core\'
,cannot find module \'angular2/router\'
,cannot find module \'angula
I had this problem on installing ionic 2 - i installed all the packages (package.json update) and updated my npm to v3. This solved it.
This is an Interesting issue, apart from the reasons and solution mentioned above, one can get this error on following scenarios.
NPM (Node Package Manager) is not installed on the machine
Fix: Install NPM from https://nodejs.org/en/
If you are still getting this error after Installing NPM, there could be NPM configuration issue. Refer to this article to setup NPM configuration properly
I too encountered this error and what worked for me was, unloading the project and checking the .csproj file. I found that this snippet was added there -
<ItemGroup>
<None Remove="ClientApp\components\componentname\componentname.ts" />
</ItemGroup>
Removing this code, saving the csproj then reloading the project worked. Hope this helps!
Easiest way to install it is with npm package manager, because angular2 is shipped with typing now. Your editor will recognize all import locations...
Just right click on "package.json"
and select "Restore Packages" after installation of Packages build it... your problem is solved