RGraph beta Line chart issue

Share RGraph:   Share or Like RGraph on Facebook!

« Back to message list

Enter your email address to get email updates on this topic. You can stop receiving updates by clicking the link in the update email messages.

Posted by Othmar on 31st August 2016
Hi Richard

If i use the current beta i got a javascript error :

 
RGraph.line.js (line 258, column 134)
TypeError: data[0] is null

near: typeof data[0][0]

...of data[0] === 'object' && typeof data[0][0] === 'number' ? data[0].length - 1 :...

Current stable is forking fine. I am back to stable.

Othmar
Posted by Richard on 31st August 2016
Hi there,

IIRC I've fixed this already but that beta was released before I did. So try replacing the entirety of that line with this (all of this should be on a single line):


'chart.numxticks': (data && typeof(data[0]) == 'number' ? data.length - 1 : (typeof data[0] === 'object' && data[0] && typeof data[0][0] === 'number' ? data[0].length - 1 : 20)),



And see if that fixes it.




Richard
Posted by Othmar on 31st August 2016
Hi Richard

Yes thats it!

Thanks,
Othmar

Add a reply




« Back to message list