react-native-swipe-list
An FlatList Component that is swipeable.
This was originally a fork of an experimental component SwipeableFlatList
which was removed from the react-native core.
Install
In order to use this package, you will also need to install react-native-gesture-handler
to your project.
yarn add react-native-swipe-list react-native-gesture-handler
Usage
;;;;; ; ;
Reference
Props
SwipeableFlatList
takes in FlatListProps
as well as the following props:
renderLeftActions
Views to be displayed when user swipes the item from the left side.
Type | Required |
---|---|
(info: ListRenderItemInfo) => React.ReactNode | No |
renderRightActions
Views to be displayed when user swipes the item from the right side.
Type | Required |
---|---|
(info: ListRenderItemInfo) => React.ReactNode | No |
closeOnScroll
When true
, swiped view will close when user scrolls.
Default is true
Type | Required |
---|---|
boolean | No |
License
The library is released under the MIT license. For more information see LICENSE
.