Describe the bug
Pull to refresh is not working even though using refreshControl. Refresh control prevents draggable-flatlist from scrolling. using two-finger I can able to scroll but that not we need.
please add support for,
onRefresh = {this.PullToRefresh}
refreshing = {this.state.iRefreshing}
I have tried for closed issue #135 as well but it also not working.
Platform & Dependencies
Thanks in advance.
Hello All,
Please use like below those who are not able to handle pull to refresh,
const App = () => {
const [refreshing, setRefreshing] = React.useState(false);
const [data,setData] = React.useState(exampleData)
const onRefresh = React.useCallback(() => {
setRefreshing(true);
wait(2000).then(() => setRefreshing(false));
}, []);
return (
refreshControl={
renderItem={renderItem}
keyExtractor={(item, index) => draggable-item-${item.key}}
onDragEnd={({ data }) => setData(data)}
/>
);
}
const styles = StyleSheet.create({
container: {
flex: 1,
marginTop: 20,
},
scrollView: {
flex: 1,
width: "100%",
backgroundColor: 'gray',
alignItems: 'center',
justifyContent: 'center',
zIndex: 1
},
dragList: {
width: "90%",
height: '90%',
zIndex: 0,
position: 'absolute',
}
});
Did you even try this code? :D you create a variable onRefresh but you never use it..
Did you even try this code? :D you create a variable onRefresh but you never use it..
use inside scroll view refreshcontrol, but this is not working in android. i think there is a gesutre problem. using two finger pull it will invoking the refresh control method, but thats not a good way.
@dev-sathish Are you sure this code works?
I'm not sure @gdoudeng. Seems it works in ios.
I'm not sure @gdoudeng. Seems it works in ios.
No problem in iOS, but not working in Android
Same problem. Works on IOS but not on Android
Most helpful comment
Did you even try this code? :D you create a variable onRefresh but you never use it..