1.0.4 • Published 4 years ago

react-native-yuu-pulldown-refresh v1.0.4

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

react-native-yuu-pulldown-refresh

Pull down to refresh component for React Native, Automatically adapt to height like a normal View Tag.

Screenshot

Installation

Using npm:

npm install --save react-native-yuu-pulldown-refresh

or using yarn:

yarn add react-native-yuu-pulldown-refresh

Usage

// Load the module

import PullRefreshView from 'react-native-yuu-pulldown-refresh';

// please use component state variable on `refreshing` prop

<PullRefreshView refreshing={false}>
  <YourContent />
</PullRefreshView>

Configurable props

Event props

Methods

none

refreshing

Whether is refreshing state.

  • true
  • false (default)

Platforms: all

enabled

Whether to enable pull down to refresh gesture

  • true (default)
  • false

Platforms: all

disableScroll

Make <YourContent /> unscrollable.

  • true
  • false (default)

Platforms: all

ControlContentComponent

Override default pull down controller.

  • React Component

Platforms: all

onPull

Receive touch move events.

  • Callback Function
  (event) => {
    event.touch: Boolean,      // have finger on Compnenet
    event.process: Number,     // 0 ~ 1 , pull down percent
  }

Platforms: all

onPullEnd

Receive touch end events.

  • Callback Function
  () => {}

Platforms: all

onRefresh

Pull down percent is more than 0.8 on onPullEnd event after.

  • Callback Function
  () => {}

Platforms: all

MIT Licensed

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago