bootstrap-waterfall
bootstrap-waterfall copied to clipboard
waterfall() is not a function
Following exactly the same with the instruction but console log waterfall() is not a function
Not sure where the problem is.
What's about console.log($.fn.waterfall)
?
Make sure the code runs after the source file successfully loaded.
Also, definitely fork the repo and run it on your local, you'll see how it works.
It means bootstrap-waterfall.js
has not yet been loaded when you're calling .waterfall()
in your page.
This is (most likely) due to linking the script directly from github: https://raw.githubusercontent.com/Mystist/bootstrap-waterfall/master/dist/bootstrap-waterfall.js or https://rawgithub.com/Mystist/bootstrap-waterfall/master/dist/bootstrap-waterfall.js
Github should not be used as cdn
. Specifically, they do not add the cors header to allow loading from all.
To fix, just download the script in your project and include from there.