How to set <Text> some text </Text>
as upper case in react native?
<Text style={{}}> Test </Text>
Need to show that Test
as TEST
.
iOS textTransform support has been added to react-native in 0.56 version. Android textTransform support has been added in 0.59 version. It accepts one of these options:
The actual iOS commit, Android commit and documentation
Example:
<View>
<Text style={{ textTransform: 'uppercase'}}>
This text should be uppercased.
</Text>
<Text style={{ textTransform: 'capitalize'}}>
Mixed:{' '}
<Text style={{ textTransform: 'lowercase'}}>
lowercase{' '}
</Text>
</Text>
</View>