could not find module angular-devkit build-angular

0 votes

The following error repeatedly occurs on the ng serve once the updating task to Angular 6.0.1 is completed.

Could not find module "@angular-devkit/build-angular" from "/home/Projects/myProjectName". 
Error: Could not find module "@angular-devkit/build-angular" from "/home/Projects/myProjectName". 
at Object.resolve (/home/Projects/myProjectName/node_modules/@angular-devkit/core/node/resolve.js:141:11) 
at Observable.rxjs_1.Observable [as _subscribe] (/home/Projects/myProjectName/node_modules/@angular-devkit/architect/src/architect.js:132:40)

However, all is in order as shown on the screen after the ng update. Trying to use folders like the deleting node_modules along with a new npm installation has not given any results yet and is not helping. Could someone please help me with this?

Feb 8, 2022 in Java by Soham
• 9,710 points
7,053 views

1 answer to this question.

0 votes

The mode must be changed to Dev Dependency for @angular-devkit/build-angular. Angular 6.0 is the software to which this pack has been newly introduced and one must try the following two options, either of which should help solve your question. 

npm install --save-dev @angular-devkit/build-angular

                           OR

yarn add @angular-devkit/build-angular --dev

To know more about Angular, It's recommended to join Angular Online Course today.

answered Feb 8, 2022 by Rahul
• 9,680 points

Related Questions In Java

0 votes
2 answers

“Could not find or load main class” mean?

Use the final modifier to enforce good initialization. Avoid returning ...READ MORE

answered Sep 18, 2018 in Java by Sushmita
• 6,920 points
4,516 views
0 votes
1 answer

How to resolve the error: could not find or load main class?

If you are getting error: could not ...READ MORE

answered May 28, 2018 in Java by Parth
• 4,640 points
11,431 views
0 votes
1 answer

Gradle - Error Could not find method implementation() for arguments

Hello @kartik, Make sure your gradle version 3.. or ...READ MORE

answered May 26, 2020 in Java by Niroj
• 82,840 points
20,819 views
0 votes
1 answer

What does “Could not find or load main class” mean?

First of all, you need to understand ...READ MORE

answered Dec 22, 2020 in Java by Gitika
• 65,770 points
1,254 views
+1 vote
1 answer

ng is not recognized as an internal or external command

I solved this problem in accordance with ...READ MORE

answered Feb 11, 2022 in Others by Rahul
• 9,680 points
16,518 views
0 votes
1 answer

Angular 9 + CLI (TypeScript) - How to stop generating .spec.ts test files

If you're using v6 and need to ...READ MORE

answered Jun 13, 2022 in TypeSript by Nina
• 3,060 points
3,413 views
+1 vote
8 answers

How can I implement process.env in Angular 5 environment?

Users do not have access to process.env ...READ MORE

answered Apr 3, 2018 in DevOps & Agile by DareDev
• 6,890 points
13,122 views
0 votes
1 answer
0 votes
1 answer

Failed to load resource: the server responded with a status of 404 (not found)

In order to avoid an error while ...READ MORE

answered Feb 8, 2022 in Java by Rahul
• 9,680 points
2,095 views
0 votes
1 answer

Uncaught referenceerror: $ is not defined

The references must be aligned or put ...READ MORE

answered Feb 8, 2022 in Java by Rahul
• 9,680 points
2,614 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP