An open API service indexing awesome lists of open source software.

https://github.com/runjuu/react-native-elastic-swipe

🎏 A simple react native swipe component with elastic effect.
https://github.com/runjuu/react-native-elastic-swipe

elastic react react-native swipe swipe-component

Last synced: 10 months ago
JSON representation

🎏 A simple react native swipe component with elastic effect.

Awesome Lists containing this project

README

          

# react-native-elastic-swipe
[![MIT Licence](https://badges.frapsoft.com/os/mit/mit.svg?v=103)](https://opensource.org/licenses/mit-license.php)
[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](https://github.com/Runjuu/react-native-elastic-swipe/pulls)
[![npm version](https://badge.fury.io/js/react-native-elastic-swipe.svg)](https://badge.fury.io/js/react-native-elastic-swipe)

A simple react native swipe component with elastic effect.

```bash
npm install react-native-elastic-swipe
```

### Props
```typescript
interface Props {
friction?: number
criticalOffsetX?: number
criticalOffsetY?: number
swipeHorizontally?: boolean
swipeVertically?: boolean
onChangeReachStateOfHorizontal?(isReachedCriticalOffsetX: boolean): void
onChangeReachStateOfVertical?(isReachedCriticalOffsetY: boolean): void
onSwipeMove?(e: GestureResponderEvent, gestureState: PanResponderGestureState): void
onSwipeEnd?(e: GestureResponderEvent, gestureState: PanResponderGestureState): void
shouldSetPanResponder?(e: GestureResponderEvent, gestureState: PanResponderGestureState): boolean
}
```

### Example
```jsx
import Swipe from "react-native-elastic-swipe";

...
render() {
return (



);
}
...
```

### Demo