Skip to content
This repository has been archived by the owner on Jul 19, 2019. It is now read-only.

Can't resolve 'chart.js' #220

Open
Legendofire opened this issue Apr 29, 2018 · 7 comments
Open

Can't resolve 'chart.js' #220

Legendofire opened this issue Apr 29, 2018 · 7 comments

Comments

@Legendofire
Copy link

I installed react-chartjs via NPM and when i try and use Pie i get the error Error Can't resolve 'chart.js' in '/home/a7meds3d/Documents/WorkSpace/MERN/CIOChatbot/node_modules/react-chartjs/lib'.

@larsdouweschuitema
Copy link

The documentation reads:

"You must also include chart.js and React as dependencies."

Run the following command:
npm install --save chart.js

@Legendofire
Copy link
Author

Legendofire commented May 2, 2018

The error message was after I installed chart.js, maybe I installed chartjs not chart.js.
Will test it again.

@Tom-Gorup
Copy link

@larsdouweschuitema This solved my problem. Thanks!

@amineb01
Copy link

amineb01 commented Sep 5, 2018

@larsdouweschuitema thank you !

@gion
Copy link

gion commented Sep 28, 2018

Why not add chart-js as an actual dependency in the package.json file?

@javaProgrammer44
Copy link

Please add these in angular.json file
"scripts": [
"node_modules/chart.js/dist/Chart.js",
"node_modules/hammerjs/hammer.min.js"
],

@kumarbitthal
Copy link

Install missing charts dependencies: charts.js & angular2-chartsjs
I installed it locally and it worked. Don't forget to import these in your code.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants