0.1.3 • Published 5 years ago
@banterstudiosuk/throttle v0.1.3
@banterstudiosuk/throttle
Throttle function
Install
npm
npm i --save @banterstudiosuk/throttle
Usage
import throttle from '@banterstudiosuk/throttle'
const handleScroll = () => console.log('scrolling')
const throttledFn = throttle(handleScroll, 100)
window.addEventListener('scroll', throttledFn, false)
License
MIT