Here I am trying a simple code but the scroll view is not working if kept inside another view. Code is like this:
return(
Top <View>
must has style flex:1
, and also <ScrollView>
has too
Update 2020-02: It will work with React.Fragment <>
and </>
or <React.Fragment>
and </React.Fragment>
. So Try this.
return(
<>
<Toolbar title={this.props.title}>
</Toolbar>
<ScrollView>
<HomeScreenTop />
<HomeScreenBottom navigator={navigator}/>
</ScrollView>
</>
);
If you are using <Form>
from native base and you want to scroll
then use KeyboardAwareScrollView
<KeyboardAwaareScrollView enableOnAndroid={true}>
.
.
</KeyboardAwareScrollView>
this will work on Android
For me, Scroll View wrapped with TouchableWithoutFeedback was causing scroll view to not function at times.
if you are using position: "absolute",
delete it and try.
You can try
<SafeAreaView>
<ScrollView>
</ScrollView>
</SafeAreaView>
Use the property flexGrow in the style, flex didnt worked for me.
<ScrollView contentContainerStyle={{ flexGrow: 1 }}>
...
</ScrollView>