npm.io
1.0.1 • Published 11 years ago

simple-scrolltop

Licence
ISC
Version
1.0.1
Deps
0
Vulns
0
Weekly
0
Stars
7

Simple scrollTop

Hey, do you need a simple scrollTop method working like jquery's scrollTop() ? This is what you need. A crossbrowsing get and set scrollTop()

Usage

import scrolltop from 'simple-scrolltop';

// get
var currentPageScrollPosition = scrolltop();

// set
scrollTop(myNewScrollPosition);

Install

With npm do:

npm install simple-scrolltop

Keywords