我想对嵌套文本应用不同的边框半径和填充样式,但据我所知,react native 还不支持。有解决方法吗?
到目前为止我尝试的是:
<Text>
<Text
style={{
backgroundColor: 'green',
borderRadius: 12,
}}>
Text1
</Text>
<Text
style={{
backgroundColor: 'blue',
borderRadius: 12,
}}>
Text2
</Text>
</Text>
预期结果:具有不同背景和边框半径的文本。
实际结果:背景不同,但没有应用边界半径