This is a link for what i really want
Guys i want to add a text behind the image(.png) in react native ? There is ImageBackground. I simply need ImageForeground.
renderContactsItem = ({ item}) => {
return (
<View style={styles.container}>
<TouchableOpacity style={styles.itemContainer}
onPress={() => this.props.navigation.navigate('Modal',{selectedItem:item},)}
>
<View style={[styles.card,{backgroundColor:item.color}]}>
<Image
style={styles.avatar}
source={ item.picture }
/>
</View>
</TouchableOpacity>
</View>
)
};
2
Answers
You should use
ImageBackground
instead ofImage
Please go through the official document – Here
You need to style your things around this. I hope this works for you and just style the components according to your requirements in case if you need something more.