[Chartjs]-Chart.js not installing with NPM

4๐Ÿ‘

โœ…

You need to have the package.json file in your directory to have this chart.js module saved locally.

To create a package.json file, use the below command,

npm init (which will ask you few questions and will create the file at the end).

Once you create your package.json try executing the npm install chart.js --save command and see if it works.

Hope this helps!

0๐Ÿ‘

I had the same issue while running webpack server in the backgorund
When I shut down the local server, package got installed no problem.

-1๐Ÿ‘

I have faced the same issue while installing chart.js using npm.

it seems you have to stop ng serve and then try npm install chart.js โ€“save because I tried the same and it is working fine in the same folder.

Leave a comment