const styles = StyleSheet.create({
viewQuestion: {
flex: 1,
flexDirection: 'row'
},
question: {
flex: 1,
margin: 5
}
});
<View style={styles.viewQuestion} resizeMode={'contain'}>
<Text style={{fontSize: 17, margin: 10, color: '#000'}}>{this.state.pointer}</Text>
<WebView source={{html: this.state.item}} style={styles.question}/>
</View>
I was set the view and webview with with flex: 1
, but it does not work. How to make webview height to auto
? I also set the height: 'auto'
in webview style, but that does not work as swell, help and thanks