I m trying to use conditional rendering (in this specific case) that would allow me to make something like :
<Image
source={{ uri: "https://images4.alphacoders.com/221/221716.jpg" }}
style={this.state.isLoaded ? styles.loaded : { display: "none" }}
onLoadEnd={() => {
console.log("test"), this.setState({ isLoaded: true });
}}
/>
The main problem is that React Native doesn't seem to be able to use its internal lifecycle functions when the display: none style is used, and thus doesn't call onLoadEnd. It doesn't log anything.
I don't have any idea how to encounter this problem while using display style props