How to fix Cannot find module 'typescript' in Angular 4?

后端 未结 11 640
遥遥无期
遥遥无期 2020-12-09 07:40

I generated Angular 4 app 3 weeks ago using the @angular/cli. After 2 weeks, I tried to run it with the command line \"ng serve\" but I am prompted an error bel

11条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-09 08:08

    I had a very similar problem after moving a working project to a new subdirectory on my file system. It turned out I had failed to move the file named .angular-cli.json to the subfolder along with everything else. After noticing that and moving the file into the subdirectory, all was back to normal.

提交回复
热议问题