@wearejust/scroll

Adds a class when scrolling past selected elements


Keywords
scroll, javascript, scrolling
License
MIT
Install
npm install @wearejust/scroll@1.0.6

Documentation

Scroll

Installation

npm install @wearejust/scroll --save-dev

Usage

var Scroll = require('@wearejust/scroll');

$(function() {
    Scroll.init();
});

With options

var Scroll = require('@wearejust/scroll');

$(function() {
    Scroll.init({
		active: 'active',
		delay: 200,
		delayHorizontal: 50,
		gap: 0.1,
		parseOnInit: true,
		priority: 'scroll-priority',
		selector: '.scroll'
    });
});