andreruffert / rangeslider.js

🎚 HTML5 input range slider element jQuery polyfill
https://rangeslider.js.org
MIT License
2.17k stars 401 forks source link

Not safe for minification #14

Closed xonecas closed 10 years ago

xonecas commented 10 years ago

When using the minified file I get syntax errors, this is because of an unsafe transformation here:

https://github.com/andreruffert/rangeslider.js/blob/master/src/rangeslider.js#L110

Simple fix, just put parenthisis around +new Date, ex:

(+new Date())
andreruffert commented 10 years ago

Thanks! In which browser do you get the syntax errors? The minified version is also used for the gh-pages example and everything works fine even in ie8...

Anyway I fixed it in v.0.2.4 it generated also a lint error...

xonecas commented 10 years ago

I got it across all browsers. I was using the unminified version and bundling it with other files using django assets.

Thank you for the quick fix!