pullhelper

1.1.8 • Public • Published

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

Readme

Keywords

Package Sidebar

Install

npm i pullhelper

Weekly Downloads

10

Version

1.1.8

License

MIT

Last publish

Collaborators

  • yusukeshibata