Quantcast
Channel: Active questions tagged flexbox - Stack Overflow
Viewing all articles
Browse latest Browse all 1307

React Native Flex:1 working but changing the hierarchy

$
0
0

here above the red component should occupy the entire screen and the button should go to the bottom

`<SafeAreaView style={{flex: 1, backgroundColor: 'red'}}> //red component<TouchableOpacity //purple component        style={{          //   flex: -1,          width: '100%',          bottom: 0,          height: 40,          backgroundColor: 'purple',          alignSelf: 'center',          justifyContent: 'center',          alignItems: 'center',        }}><Text>Add New Note</Text></TouchableOpacity></SafeAreaView>`

The issue screenshot of output

i want the purple touchable opacity to go to the bottom of the screen


Viewing all articles
Browse latest Browse all 1307

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>