Angular-cli: ERROR in node_modules/@angular/platform-browser-dynamic/src/compiler_factory.d.ts

Created on 20 Jul 2018  路  4Comments  路  Source: angular/angular-cli

Hi all

Used typescript 2.7.2 but giving me following error

ERROR in node_modules/@angular/platform-browser-dynamic/src/compiler_factory.d.ts(18,22): error TS2720: Class 'CompilerImpl' incorrectly implements class 'Compiler'. Did you mean to extend 'Compiler' and inherit its members as a subclass?
Property 'getModuleId' is missing in type 'CompilerImpl'.
node_modules/@angular/platform-browser-dynamic/testing/src/compiler_factory.d.ts(12,22): error TS2720: Class 'TestingCompilerImpl' incorrectly implements class 'TestingCompiler'. Did you mean to extend 'TestingCompiler' and inherit its members as a subclass?
Property 'getModuleId' is missing in type 'TestingCompilerImpl'

repro steps

Most helpful comment

I managed to solve this by checking the libraries.

  1. Type npm outdated to check the version of each library.
  2. The angular-platform-dynamic library could be outdated so install it with npm i @angular/platform-browser-dynamic.
  3. You will also require tslib. So also install that with npm i tslib.
    4 Then try ng serve.

All 4 comments

I'm sorry, but we don't understand the problem you are reporting.

If the problem persists, please open a new issue, provide a simple repository reproducing the problem, and describe the difference between the expected and current behavior. You can use ng new repro-app to create a new project where you reproduce the problem.

I managed to solve this by checking the libraries.

  1. Type npm outdated to check the version of each library.
  2. The angular-platform-dynamic library could be outdated so install it with npm i @angular/platform-browser-dynamic.
  3. You will also require tslib. So also install that with npm i tslib.
    4 Then try ng serve.

Closing as it looks like a solution was provided above.

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

_This action has been performed automatically by a bot._

Was this page helpful?
0 / 5 - 0 ratings