我正在使用“react-native-svg-chart”来创建饼图,但我面临的问题是它在饼图的中心呈现重复的文本(下图)。
这是我正在使用的代码
<PieChart
style={{height: 262}}
valueAccessor={({item}) => item.amount}
data={data}
outerRadius={'95%'}>
<Text
style={{
position: 'absolute',
left: deviceWidth / 2.3 - labelWidth / 3,
textAlign: 'center',
}}>
hello
</Text>
<Labels />
</PieChart>