react-native-charts-wrapper
react-native-charts-wrapper copied to clipboard
No proper documentation
Facing the same problem here.
I checked the usage of the corresponding attributes through the source code
For me, I check from here and Example to test. lol
How do I format x-axis with proper format. I'm passing the values like below but my app crashes
<LineChart legend={{ enabled: false }} chartDescription={{ text: '' }} xAxis={{ enabled: true, valueFormatter: 'date', valueFormatterPattern: 'MMM DD', position: 'BOTTOM', granularityEnabled: true, granularity: 1 }} yAxis={{ left: { enabled: true, }, right: { enabled: false } }} style={{ width: '100%', height: 400 }} data={[{"dataSets":[{"values":[{"x":1637884800,"y":1081.92},{"x":1637712000,"y":1116},{"x":1637625600,"y":1109.03},{"x":1637539200,"y":1156.87},{"x":1637280000,"y":1137.06},{"x":1637193600,"y":1096.38},{"x":1637107200,"y":1089.01},{"x":1637020800,"y":1054.73},{"x":1636934400,"y":1013.39},{"x":1636675200,"y":1033.42},{"x":1636588800,"y":1063.51},{"x":1636502400,"y":1067.95},{"x":1636416000,"y":1023.5},{"x":1636329600,"y":1162.94},{"x":1636070400,"y":1222.09},{"x":1635984000,"y":1229.91},{"x":1635897600,"y":1213.86},{"x":1635811200,"y":1172},{"x":1635724800,"y":1208.59},{"x":1635465600,"y":1114},{"x":1635379200,"y":1077.04}],"label":"","config":{"mode":"HORIZONTAL_BEZIER","drawCircles":false,"drawValues":false,"color":4290864481,"lineWidth":1,"fillAlpha":40}}]}} />
For me, I check from here and Example to test. lol
ChartDataConfig and ChartDataSetConfigalso helped me decipher some of the config