xxxxxxxxxx
text = text.replace(/<br\s*\/?>/gi, "\n")
xxxxxxxxxx
you need use {'\n'} as line breaks in text component, whenever you need to add line break in react native application
xxxxxxxxxx
<View style={styles.lineUnder}>
<Text>example text</Text>
</View>
const styles = StyleSheet.create({
lineUnder: {
borderBottomColor: 'black',
borderBottomWidth: 1,
}
});