the shadow property of the expo react native for android only has elevation and opacity , cant i change the color of the shadow somehow for my components in my app
other shadow properties are deprecated, i want to apply all styling to my shadow like offset, color, etc
2
Answers
cant you apply stylesheet style as shadow
like
container: {
width: ‘100%’,
//shadow
shadowColor: ‘#000’,
shadowOffset: {
width: 0,
height: 2,
},
shadowOpacity: 0.1,
shadowRadius: 1,
elevation: 4,
},
shadow property for android is limited compared to ios. android uses elevation property but this doesn’t allow to customize shadow color directly. however, you can achieve similar effects by using react-native-shadow-2 library.