Scroll Fire Directive

“Scroll Fire” is a directive that enables a method to be called (once and only once) when user scrolls current page and the DOM element (or component) that it is applied to comes into the viewport.

TIP

There is also a Scroll directive which fires whenever user scrolls the page.

Installation


// quasar.conf.js

return {
  framework: {
    directives: [
      'ScrollFire'
    ]
  }
}

Usage

Basic



IMPORTANT

For performance purposes, the scroll listener function injected is by default debounced by 50ms.

Determining Scrolling Container

Please read here about how Quasar determines the container to attach scrolling events to.

API