对角线穿过文本 React-Native

Mok*_*umJ 6 react-native

我正在寻找一种在反应本机上通过文本元素制作对角线的方法。

使用 :after 元素和 css 这应该是可能的,但这在 React-Native 中不可用。

有人提出很酷的建议吗?

Mok*_*umJ 6

最终,我遇到了一种情况,画了一条带有旋转的绝对定位线。

<View
                style={{
                    position: 'absolute',
                    transform: [ {rotate: '17deg'} ],
                    top: 7,
                    width: 25,
                    height: 1,
                    borderBottomColor: styleGuide.errorColorRed,
                    borderBottomWidth: 1,
                }}/>
Run Code Online (Sandbox Code Playgroud)