Closed aLemonFox closed 2 years ago
Try adding overflow: 'hidden' to the style.
<Chart
style={{ flex: 1, borderWidth: 5, borderRadius: 10, overflow: 'hidden' }}
data={[{ x: 0, y: 5 }, { x: 1, y: 10 }, { x: 2, y: 5 }, { x: 3, y: 10 }]}
xDomain={{ min: 0, max: 3 }}
yDomain={{ min: 0, max: 20 }}
>
<Area smoothing={'cubic-spline'} theme={chartStyles.area} />
</Chart>
Forgot this issue was still open. Setting overflow: 'hidden'
works. Thanks @apfz!
Is it possible to use
borderRadius
prop on<Chart>
? Currently the area doesn't match the parents bounds: