Sticky

Example


Installation

$ npm i -S storm-sticky

Usage

HTML

CSS

Sample minimum CSS required

JS

Either import and initialise using a named import:

import Sticky from 'storm-sticky';
            
Sticky.init('.js-sticky');

Or async using storm-load.js, add the .standalone file to your project, then initialise using the global name:

Load('/content/js/async/storm-sticky.standalone.js')
.then(() => {
    StormSticky.init('.js-sticky');
});