2

Try to run following command for implement AOT in angular2

npm install @angular/compiler-cli typescript@next @angular/platform-server @angular/compiler

but gives me error, also can you give me step by step how i compile application for AOT

Also how i can run the node_modules/.bin/ngc -p tsconfig-aot.json command

UNMET PEER DEPENDENCY [email protected] invalid
npm WARN @angular/[email protected] requires a peer of typescript@^2.0.2 but none was installed.
npm WARN @angular/[email protected] requires a peer of @angular/[email protected] but none was installed.
npm WARN @angular/[email protected] requires a peer of @angular/[email protected] but none was installed.
npm WARN @angular/[email protected] requires a peer of @angular/[email protected] but none was installed.
npm WARN @angular/[email protected] requires a peer of @angular/[email protected] but none was installed.
npm WARN @angular/[email protected] requires a peer of @angular/[email protected] but none was installed.
npm WARN @angular/[email protected] requires a peer of typescript@^2.0.2 but none was installed.
1

1 Answer 1

1

This error is caused by unmet dependencies. You should install a newer version of angular2. After that, run the command again. Browse root path of your project and run the command below.

node_modules/.bin/ngc -p tsconfig-aot.json

You can get a detailed explanation from here.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.