Skip to content

Commit 72d8565

Browse files
Daniel ToplakIonDen
Daniel Toplak
authored andcommitted
fix: only require jQuery if it is not defined (#476)
When jQuery is included e.g. via a <script> tag then there is a glitch with the required version.
1 parent f0e1116 commit 72d8565

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

js/ion.rangeSlider.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@
1111
// =====================================================================================================================
1212

1313
;(function(factory) {
14-
if (typeof define === "function" && define.amd) {
14+
if (!jQuery && typeof define === "function" && define.amd) {
1515
define(["jquery"], function (jQuery) {
1616
return factory(jQuery, document, window, navigator);
1717
});
18-
} else if (typeof exports === "object") {
18+
} else if (!jQuery && typeof exports === "object") {
1919
factory(require("jquery"), document, window, navigator);
2020
} else {
2121
factory(jQuery, document, window, navigator);

0 commit comments

Comments
 (0)