Error: Cannot find module '@angular-devkit/core' - after clean install
Versions
_ _ ____ _ ___
/ \ _ __ __ _ _ _| | __ _ _ __ / ___| | |_ _|
/ △ \ | '_ \ / _` | | | | |/ _` | '__| | | | | | |
/ ___ \| | | | (_| | |_| | | (_| | | | |___| |___ | |
/_/ \_\_| |_|\__, |\__,_|_|\__,_|_| \____|_____|___|
|___/
Angular CLI: 1.6.4
Node: 6.11.0
OS: win32 x64
Angular: _(yup, I don't see it, but I install it 2 days ago)_
...
Repro steps
- ng new e-commerce-with-tut-ng4
- cd e-commerce-with-tut-ng-4
- ng serve (to test if works)
Observed behavior
After that I've got this ->
C:\Users\TheTanadu\Desktop\codetemp\e-commerce-with-tut-ng4>ng serve
module.js:471
throw err;
^
Error: Cannot find module '@angular-devkit/core'
at Function.Module._resolveFilename (module.js:469:15)
at Function.Module._load (module.js:417:25)
at Module.require (module.js:497:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (C:\Users\TheTanadu\Desktop\codetemp\e-commerce-with-tut-ng4\node_modules\@angular-devkit\schematics\src\tree\virtual.js:10:16)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
After all I came here but when I wanted to use ng --version in this path I've got same error like that what is up and I had to go cd .. and then use ng -v
Desired behavior
I wanted to see local server
Mention any other details that might be useful (optional)
Windows 10
thank u @LarsMengel
Thanks @LarsMengel. That was fast and solved my problem.
had same issue....did npm install -g @angular/cli@latest and it resolved.
Thanks man! Problemo solved!
Thanks @LarsMengel ! Worked like a charm!
this work for me npm i -D@angular-devkit/core
@LarsMengel Thanks ! Worked for me too. Using now Angular ^1.6.8.
The solution by @LarsMengel worked like a charm.
Thank you!
npm install --save-dev @angular/cli@latest
fixed the issue for me.
I am having the same issue, for some reason my Angular CLI/npm isn't downloading "node_modules@angular-devkit\core".
To fix it I copied "my node_modules@angular-devkit\core" folder from a 3 month old project into the project that I am trying to create now and that fixed the issue...
I had the same issue and here is how I resolved it ( today ) the current version is 1.7.0 I updated to the latest with
npm update -g @angular/cli
then I removed the project i created with previous version of @angular/cli then I started a new one again with
ng new projectName
@LarsMengel please update your answer
@mehany No update necassary, cause '^' will take the newest version anyway.
I can verify the solution still works, had the same problem this moring 👍
I have solved the above issue through this command: npm install --save-dev @angular/cli@latest
Thanks ! Works fine !
It really is an issue with the version, as soon as I updated mine to 1.6.5 (npm install -g @angular/[email protected]) the issue went away!
@LarsMengel helped!!, thank you. :+1:
Thanks @LarsMengel ... Your solution works like a CHARM ...
Thank you @LarsMengel worked like a charm. Thanks a lot.
@LarsMengel Thank You for the solution. It worked for me too.
- npm update -g @angular/cli
- editing package.json changing the line "@angular/cli": "1.x.x" to "@angular/cli": "^1.x.x",
- npm update
Thanks @LarsMengel !