@bicycle-codes/raf-scroll
v0.0.2
Published
Scroll events, debounced with `requestAnimationFrame`
Downloads
52
Maintainers
Readme
raf scroll
Scroll events, debounced with requestAnimationFrame
.
install
npm i -S @bicycle-codes/raf-scroll
example
import { rafScroll } from '@bicycle-codes/raf-scroll'
rafScroll(ev => {
// this is called at most once per animation frame
console.log('scroll event', ev)
})
use minified scripts
import { rafScroll } from '@bicycle-codes/raf-scroll/min'