python ruby-programming-language Smalltalk Vue.js Knockoutjs TypeScript JavaScript, OOPs JavaScript Angular 8,7,6,5,4 and 2 Interview Questions and Answers Angular 8,7,6,5,4 and 2 Interview Questions and Answers Angular 4 Angular 2 AngularJs 1.x NodeJs Perl Programming R Programming RequireJs Rust Programming Backbonejs closure programming language go-programming-language kotlin-programming-language
cannot find module 'angular2/core'

cannot find module 'angular2/core'

In Visual Studio 2013, the configurations of typescript is little bit challenging but you can configure typescript manually easily.

Following steps as given below.

Step 1

In the Step1, right-click on your project and Unload Project.

Step 2

In the Step 2, right-click the unloaded project and edit to .csproj file.

Step 3

In the Step 3, add a PropertyGroup node in under the project node which is given below.
  <PropertyGroup Condition="'$(Configuration)' == 'Debug'">


  <PropertyGroup Condition="'$(Configuration)' == 'Release'">
    <TypeScriptOutFile />
    <TypeScriptOutDir />
    <TypeScriptMapRoot />
    <TypeScriptSourceRoot />

Step 4

In Step 4, right-click on unloaded project and reload to unload project.

Step 5

In Step 5, re-build your project now.

Notes :  

If you still facing same error, restart you visual studio web project.

If you are using Visual Studio 2015, you don't need to edit ".csproject" file, you could directly change in "tsconfig.json"(typescript configuration) file by adding "emitDecoratorMetadata: true".

I think, I might help you!


Hi there! Welcome to my blog. My name is Anil Singh. I'm a author of this blog. For more detail about me, kindly refer to this link..
My Blogs - and
My Books - Interview Questions and Answers Books- Get Your Book in 15+ Digital Stores Worldwide..

You Might Also Like Powered by Blogger.
ASK Questions