docs/wiki/07-migration-from-1x.md
This page summarizes migration to 2.0.0.
@EnvironmentObject.| 1.x | 2.x |
|---|---|
LineChartView | LineChart |
BarChartView | BarChart |
PieChartView | PieChart |
MultiLineChartView | multiple LineChart layers |
| 1.x | 2.x |
|---|---|
.data(...) | .chartData(...) |
.rangeX(...) | .chartXRange(...) |
.rangeY(...) | .chartYRange(...) |
.setAxisXLabels(...) | .chartXAxisLabels(...) |
.setNumberOfHorizontalLines(...) | .chartGridLines(...) |
.showChartMarks(...) | .chartLineMarks(...) |
Pick one:
.chartInteractionValue(ChartValue()).chartSelectionHandler { event in ... }See MIGRATION.md for complete type + method mapping.