Track How Far You Are Scrolling – Scrolld

Category: Javascript | August 28, 2019
Author: hallojoe
Views Total: 155 views
Official Page: Go to website
Last Update: August 28, 2019
License: MIT


Track How Far You Are Scrolling – Scrolld


Yet another scroll position detection library which tracks how far a web page has been scrolled.

You can use the library to create a scroll position indicator that indicates the scrolling/reading progress as the user scrolls down the web page.

How to use it:

Install & Download the Scolld.

$ npm install scrolld --save

Import the scrolld.min.js into the document.

<script src="scrolld.min.js"></script>

Or from the CDN.

<script src="[email protected]/dist/scrolld.min.js"></script>

Initialize the scrolld library and done.

var scrolld = new Scrolld();

You might need to track the scroll position in a specific container. E.g. article.

var scrolld = new Scrolld(document.querySelector('#article'));

Get the current scroll position.



You Might Be Interested In:

Leave a Reply