Reputation: 23793
I'm using chartist on my website. On localhost, it's fine. Everything is working.
When i deploy the website, i get 2 errors when i want to draw pie chart.
Others charts are working well.
The errors are the following :
Uncaught TypeError: Cannot set property 'chartist' of null
It refers to that part of code : return m.chartist=y,y
Uncaught TypeError: Cannot read property 'series' of undefined
It refers to that part of code: for(var t=[],n=0;n<e.series.length;n++)t[n]="object"==typeof e.series[n] ...
The only differences between dev and prod version is that i concat my JS (not uglify).
I can't give you more detail so I know it won't be easy for you to help, but i'm lost I spent hours on this and i still haven't figure it out. Any help would be really appreciated!
Thanks
Upvotes: 0
Views: 880
Reputation: 7592
Try eliminating all differences between your production and development code. In this case, you are minifying the code first so try using it in production without minifying.
If it solves the problem, then you'll know something is going on in the minifying process.
Upvotes: 1