We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 32cf4d9 commit 251298eCopy full SHA for 251298e
src/jquery-ias.js
@@ -324,9 +324,15 @@
324
* @public
325
*/
326
IAS.prototype.initialize = function() {
327
- var currentScrollOffset = this.getCurrentScrollOffset(this.$scrollContainer),
+ var supportsOnScroll = (!!('onscroll' in this.$scrollContainer.get(0))),
328
+ currentScrollOffset = this.getCurrentScrollOffset(this.$scrollContainer),
329
scrollThreshold = this.getScrollThreshold();
330
331
+ // bail out when the browser doesn't support the scroll event
332
+ if (!supportsOnScroll) {
333
+ return false;
334
+ }
335
+
336
this.hidePagination();
337
this.bind();
338
0 commit comments