Any issues with sparklines and jQuery 3.2.0?

152 views
Skip to first unread message

Scott Carpenter

unread,
Mar 29, 2017, 3:32:18 PM3/29/17
to jQuery Sparkline
I had an oldish web application I was using jquery 1.7.1 and sparklines 2.1.2 and everything was working AMAZING once I got used to it

Then today I decided to upgrade my jQuery to 3.2.0 and worked out the rest of the bugs between versions and now my sparkline doesn't work.

In Chrome I asked the debugger to stop on all exceptions and it produced this result for me 

    DOMException: Failed to execute 'querySelectorAll' on 'Element':'*,:x' is not a valid selector

Any ideas? I've attached the sparkline js file I'm using on my server

Thanks for any help you can provide!
jquery.sparkline.js

Scott Carpenter

unread,
Mar 29, 2017, 3:47:05 PM3/29/17
to jQuery Sparkline
Sorry I just noticed those uncaught exceptions are in the jQuery3.2.0 file ... so I don't think of any relevance, but sparkline is still not working, no errors or funny stuff just a blank line chart

Scott Carpenter

unread,
Mar 29, 2017, 3:56:27 PM3/29/17
to jQuery Sparkline
I fixed it, I was making my charts big by setting the font size in the style part of the span or div but when I changed over, the height was no longer setting based on that css attribute

I was using html tags sparkwidth='400' to set the width but wasn't specifying the height there and so the canvas height was 0

once I added the tag option sparkheight='80' everything was back to normal


On Wednesday, March 29, 2017 at 3:32:18 PM UTC-4, Scott Carpenter wrote:

Justin Warwick

unread,
Jan 30, 2019, 11:10:43 AM1/30/19
to jQuery Sparkline
Scott: as soon as I upgrade to jquery 1.9, even on the semi-official jsfiddle, the sparkline no longer works. On my own testing, $.sparkline() function is no longer defined with versions of jquery past 1.8 series. Did you have to do something special or did you find a fork of sparkline that has jquery 3 compatibility? 
Reply all
Reply to author
Forward
0 new messages