Licence
ISC
Version
1.0.3
Deps
0
Size
4 kB
Vulns
0
Weekly
0
Scroll Indicator JS
A simple vanilla JS scroll indicator. No dependencies, best performances.

Get Started
With yarn
yarn add scroll-indicator-js
With npm
npm i scroll-indicator-js
To use it in your app
// main.js
import scrollIndicator from 'scroll-indicator-js'
scrollIndicator() // Start the scroll indicator on all .scroll-indicator classes
Usage
<!-- On the top of your page -->
<div class="scroll-indicator" data-height="5px" data-position="bottom"></div>
<!-- ..... -->
| datasets | Value | Default |
|---|---|---|
| height | px | 3px |
| position | top - bottom - left - right | top |
| color | hex/rgba/linear | linear-gradient(225deg,#ffb938 0%,#ff5729 100%) |
| reverse | true - false | false |