Attempting to use this library with no luck. When I add the following code to one of my components...
import { Line as LineChart } from 'react-chartjs-2'
render() {
<LineChart data={data} />
)
I get this error message:
Warning: Failed prop type: Cannot read property 'line' of undefined
Has anyone come across this and figured out a solution?
I'm using:
"chart.js": "^2.7.2",
"react-chartjs-2": "^2.7.4",
Hello @nathanburgess have you got this sorted? I am having similar issue. Thanks
@sameerjain I didn’t mess with it too much. The trouble of fixing it wasn’t worth it. Instead I went with ChartKick for now, which works with no problems.
Restarting node service fixed this for me, may be module doesn't compiled
well because I installed it while npm start was running. All good now.
Cheers
Keep it positive !!
Warm Regards,
Sameer Jain
+91-98281-23519
+91-98281-23510
On Mon, Aug 13, 2018 at 8:56 PM, Nathan Burgess notifications@github.com
wrote:
@sameerjain https://github.com/sameerjain I didn’t mess with it too
much. The trouble of fixing it wasn’t worth it. Instead I went with
ChartKick for now, which works with no problems.—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/jerairrest/react-chartjs-2/issues/318#issuecomment-412558165,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACS3bHrTElL_bU_KoanEv68XzBCSzUi-ks5uQZqtgaJpZM4VtLdP
.
That didn’t work for me. I even tried deleting node_modules and clearing the cache, forcing everything to redownload and rebuild.
Thanks,
Nathan Burgess
On Aug 13, 2018, 08:39 -0700, AugustLeo notifications@github.com, wrote:
Restarting node service fixed this for me, may be module doesn't compiled
well because I installed it while npm start was running. All good now.
CheersKeep it positive !!
Warm Regards,
Sameer Jain
+91-98281-23519
+91-98281-23510On Mon, Aug 13, 2018 at 8:56 PM, Nathan Burgess notifications@github.com
wrote:@sameerjain https://github.com/sameerjain I didn’t mess with it too
much. The trouble of fixing it wasn’t worth it. Instead I went with
ChartKick for now, which works with no problems.—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/jerairrest/react-chartjs-2/issues/318#issuecomment-412558165,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACS3bHrTElL_bU_KoanEv68XzBCSzUi-ks5uQZqtgaJpZM4VtLdP
.—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
I am using following version from both lib
"chart.js": "^2.6.0",
"react-chartjs-2": "^2.7.4",

After spending half a day trying to get this to work in a new watered down react app, I'm giving up
I had the same problem which I fixed updating the chart.js dependency.
v2.3.7 is the current version by now.
run npm install [email protected] --save
I too am having this problem, please help!
Please create new issues if you are still experiencing issues with the latest versions of both libraries. Include a sandbox example if possible.
Closing
Most helpful comment
I am using following version from both lib