I don't understand why jQuery 2 and 3 won't work, both giving "Uncaught ReferenceError: $ is not defined"
Hello
I'm getting pretty confused about the 3 different jQuery branches, so I'm using both chrome and firefox (up-to-date) but I'm getting "Uncaught ReferenceError: $ is not defined" when using the newest 3.1.1 jQuery or 2.2.4... However when I use 1.12.4 everything works, which is strange to me.
I'm loading jQuery google CDN as first thing in my pug file:
and I'm getting an error:
- jquery.min.js:4 Uncaught TypeError: a.indexOf is not a function
- at r.fn.init.r.fn.load (jquery.min.js:4)
- at index.html:12
So it means I can't load jQuery 3.1.1? It says there are mistakes in it's own file? (it is the only js file I load btw)
2.2.4 gives error "Uncaught ReferenceError: $ is not defined" on:
- $('#arrow').hide();
- $(window).load(function(){ ...
which looks like good jQuery to me.
I am really confused about jQuery actually, 3.1.1 gives errors in it's own file, I can't use $ with 2.2.4, and everything is normal with 1.12.4 which is the oldest right?
If you could tell me how to troubleshoot this or explain me why the 2 newest jQuery branches giving so many errors that would be greatly appreciated.
Greetings Sebastiaan