pullhelper
v1.1.8
Published
pull to refresh navigation helper
Downloads
47
Readme
pullhelper
Pull to reflesh navigation helper.
Install
npm install pullhelper
Usage
import PullHelper from 'pullhelper'
const pullhelper = new PullHelper()
pullhelper
.on('step', (step) => {
console.log(step)
})
.on('stepback', (step, next) => {
next(step / 2)
})
.on('pull', (step, next) => {
if(step < 100) {
next()
return
}
// proceed to next phase next is called
setTimeout(next, 2000)
})
.load()
// unload
pullhelper.unload()
Demo
Demo using with react.js.
https://yusukeshibata.github.io/pullhelper/
License
MIT