react-native-photo-view
react-native-photo-view copied to clipboard
onLoad, onLoadEnd not working on IOS
<PhotoView
source={{uri: this.state.url}}
style={styles.imageWV}
onLoad={() => console.log('Image loaded')}
/>
onLoad, onLoadEnd not working on IOS. It is working fine on Android.
react-native-cli: 2.0.1 react-native: 0.51.0
Can confirm this. Like the sluggish animation, this was also working for me in RN 0.49 and after upgrading to 0.51 it stopped working.
facing the same issue with RN 0.52.2
Look my PR #122
Same here
Who wants to try my solution, use my Fork:
(remember, this will work for RN >= 0.50.0)
"react-native-photo-view": "git+https://github.com/douglasjunior/react-native-photo-view.git#patch-2"
@douglasjunior your fork works fine for this but add me a white background I cannot change, so basically I switch a bug for an another one ;)
I then did my own fork, with backgroundColor + onLoad/End events, which juste merge PR #127:
yarn add git+https://github.com/drpiou/react-native-photo-view.git
@drpiou backgroundColor white is in the current version of react-native-photo-view, so I dont changed that.