react-native-chart-kit
react-native-chart-kit copied to clipboard
How to remove the spacing between the bars in BarChart?
My code:
<BarChart
data={data}
width={Dimensions.get('window').width}
height={220}
showValuesOnTopOfBars
yAxisSuffix=""
segments={3}
style={{
borderRadius: 24,
marginVertical: 16,
paddingRight: 72,
paddingHorizontal: 16,
}}
chartConfig={{
backgroundColor: colors.red,
backgroundGradientFrom: colors.red,
fillShadowGradient: colors.white,
fillShadowGradientOpacity: 1,
backgroundGradientTo: colors.red,
decimalPlaces: 2,
color: (opacity = 1) => `rgba(255, 255, 255, ${opacity})`,
data: data.datasets,
backgroundGradientFromOpacity: 75,
backgroundGradientToOpacity: 30,
propsForLabels: {
fontSize: '11',
},
propsForBackgroundLines: {
strokeDasharray: '',
},
}}
/>
any solution ??