react-native-swipeout
react-native-swipeout copied to clipboard
How to disable parent scrolling inside a <Swipeout/> Component ?
Also looking for this. Documentation says scroll
property takes a function...
Last comment in https://github.com/dancormier/react-native-swipeout/issues/179
<Swipeout>
scroll={(scrollEnabled) => { this.setState({ scrollEnabled }); }}
...
</Swipeout>
<FlatList
scrollEnabled={this.state.scrollEnabled}
...
</FlatList>
i did it like this:
<Swipeout>
scroll={() => { this.setState({ scrollEnabled: false }); }}
onClose={() => { this.setState({ scrollEnabled: true }); }}
...
</Swipeout>
<FlatList
scrollEnabled={this.state.scrollEnabled}
...
</FlatList>