The Angular Compiler requires TypeScript >=2.7.2 and <2.8.0 but 2.8.3 was found instead

前端 未结 9 1449
失恋的感觉
失恋的感觉 2020-12-24 05:25

I starting getting this error on my Angular app:

The Angular Compiler requires TypeScript >=2.7.2 and <2.8.0 but 2.8.3 was found instead

9条回答
  •  梦毁少年i
    2020-12-24 05:40

    I did next steps:

    • removed package-lock.json;
    • npm install -g --save typescript@2.7.2;
    • npm uninstall -g --save typescript@2.9.2;
    • in package.json, section "devDependencies" updated string with typescript as "typescript": "~2.7.2".

    After all above run in project's terminal ng serve --open (I've been using IDEA 2018.1).

提交回复
热议问题