我看到很多react原生库都这样使用这个api。是否支持android平台?">
我试着在安卓设备上使用ScrollView的onResponderRelease事件,但效果不佳。代码如下:
<ScrollView
onResponderRelease = {()=>{console.log('release')}}
/>
我看到很多react原生库都这样使用这个api。是否支持android平台?
发布于 2017-11-10 12:13:07
是的,它有这样的问题-你可以阅读更多关于这个https://github.com/facebook/react-native/issues/9447的信息
尝试使用'onMomentumScrollEnd',在某些情况下,它将执行您所期望的操作:
<ScrollView
onMomentumScrollEnd = {()=>{console.log('release on Android')}}
onResponderRelease = {()=>{console.log('release on IOS')}}
/>
https://stackoverflow.com/questions/35915389
复制