Open angarc opened 4 years ago
I've tried:
text: { textAlign: 'center' }
but that doesn't work.
I've also tried adding the same styling to the View that surrounds the Markdown, but that doesn't work either.
When I try
paragraph: { textAlign: 'center' }
that messes up everything! in fact, even if i just add
paragraph: {}
then all the text gets ruined and displays only one word per line for some reason.
How can I center align text?? Here are all the relevant bits:
renderDescription(description) { if (description === '' || description === null) return return (<Markdown styles={styles.resource.description}>{description}</Markdown>) } <View key={resource.id} style={styles.resource.container}> { this.renderDescription(resource.description) } </View> const styles = { resource: { container: { marginTop: 20, marginBottom: 20, }, description: { view: { marginTop: 10 }, text: { fontFamily: 'Gotham-Book', textAlign: 'center', // Doesn't work }, }, } }
Any updates?
I've tried:
but that doesn't work.
I've also tried adding the same styling to the View that surrounds the Markdown, but that doesn't work either.
When I try
that messes up everything! in fact, even if i just add
then all the text gets ruined and displays only one word per line for some reason.
How can I center align text?? Here are all the relevant bits: