how to set height to scroll view in react native code example
Example 1: styling scrollview height in react native
<ScrollView contentContainerStyle={{ flexGrow: 1, height: '100%'}}>
</ScrollView>
Example 2: react native scrollview set height
render() {
return (
<View style={styles.container}>
<View style={{height: 80}} >
<ScrollView
horizontal
style={{ backgroundColor: 'blue'}}
>
<Text style={{padding: 24}} >title1</Text>
<Text style={{padding: 24}} >title2</Text>
<Text style={{padding: 24}} >title3</Text>
<Text style={{padding: 24}} >title4</Text>
<Text style={{padding: 24}} >title5</Text>
</ScrollView>
</View>
</View>
);
}