width react-native code example
Example 1: device height react native
import { Dimensions } from 'react-native';
console.log({
width: Dimensions.get('window').width,
height: Dimensions.get('window').height
})
Example 2: how to take 100% width in react native
header : {
height : 100,
backgroundColor: "favorite color",
alignSelf: "stretch",
}