Here's the simplest code possible:
export default class App extends React.Component {
render() {
return (
<View style={styles.container}>
<Image resizeMode={'contain'} source={imageSource}/>
</View>
)
}
}
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#fff',
alignItems: 'center',
justifyContent: 'center',
},
})
If the resizeMode is set on 'center', it's working nearly as expected, but when in 'contain', the image does not resize. The image is really huge, but it does not resize... Where am I wrong? :)
resizeMode="contain"