(New to ReactNative)
I currently have a React Native app which has a component with the following (rough) structure :
<View>
<View>
<TextInput />
<Text />
</View>
<View>
<Image />
<Button />
</View>
</View>
So within that parent View, let's call the children View1 and View2. I can very easily substitute the parent View for ScrollView and have the whole component be scrollable. However, what if I want only View2 to be scrollable and View1 to stay in place? And I mean vertical scrolling, not horizontal scrolling/pagination.
How can I do this? Switching out View2 for ScrollView does not work. I'm also looking for solutions where I wouldn't have to split those View1 and View2 into different components because there's a complex mechanism currently in place which relies on sharing state between the two.
Any suggestions? Happy to provide some of the actual code if necessary but I believe the above should be enough to get a feel for it.
Thanks in advance.