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

ListEmptyComponent not taking full screen with flex 1 in React Native Section List

$
0
0

So I am using React Native Section List and following is my Code of ListEmptyContent

// define your stylesconst styles = StyleSheet.create({  container: {    justifyContent: 'center',    alignItems: 'center',    backgroundColor: '#fff',    marginLeft: 10,    marginRight: 10,  },  imageStyle: {    width: 140,    height: 120,  },  titleStyle: {    fontSize: 14,    color: '#363a45',  },  subTitleStyle: {    fontSize: 12,    color: '#898d97',  },});// create a componentconst GPEmtptyTransaction = ({ firstLine, secondLine }) => {  return (<View style={styles.container}><Image source={images.emptyTransactionIcon} style={styles.imageStyle} /><Text style={styles.titleStyle}>{firstLine}</Text><Text style={styles.subTitleStyle}>{secondLine}</Text></View>  );};

But when EmptyTemplate is rendered it is rendered on Top and not stretching to full 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>