Interspace between text Lines in React native
TextReact NativeText Problem Overview
I need to change the space between lines in a text in a React Native for both android and iOS. This is the code in the styles pages:
text: {
color: '#C0C0C0',
fontSize: 18,
textAlign: 'justify',
}
Text Solutions
Solution 1 - Text
Use lineHeight
-
text: {
color: '#C0C0C0',
fontSize: 18,
textAlign: 'justify',
lineHeight: 30,
},
Solution 2 - Text
You can use
{'\n'}
inside your Text tag
example :
<Text>{'\n'} Heading : </Text>