scroll-navigation-menu
A library to perform animated scrolling between sections and set active state in anchors as scroll happens.
Installation
the package can be installed using npm
npm install --save scroll-navigation-menu
Usage
Markup:
You just need to add sections with ids and anchors pointing to them.
About Videos Footer This is the about section Watch videos here! This is the end
Style
Style is optional, it is needed to highlight the active section's anchors.
Javascript
; const scrollNavigation = ;scrollNavigationstart;
Options
An Options object can be passed when initializing ScrollNavigation. the options with their defaults are:
animationDuration: 233 activeClass: 'active' linksSelector: '.scroll' offset: 0