<chart :title-text="'Gross domestic product growth /GDP annual %/'"
:legend-position="'bottom'"
:series-defaults-type="'area'"
:category-axis-categories="categoryAxisData"
:category-axis-major-grid-lines-visible="false"
:category-axis-labels-rotation="'auto'"
:value-axis-labels-format="'{0}%'"
:value-axis-line-visible="false"
:value-axis-axis-crossing-value="-10"
:tooltip-visible="true"
:tooltip-format="'{0}%'"
:tooltip-template="tooltipTemplate"
:theme="'sass'">
<chart-series-item :name="'India'"
:data="indiaData"
:line-style="'smooth'">
</chart-series-item>
<chart-series-item :name="'World'"
:data="worldData"
:line-style="'smooth'">
</chart-series-item>
<chart-series-item :name="'Haiti'"
:data="haitiData"
:line-style="'smooth'">
</chart-series-item>
</chart>
When using the ChartSeriesItem tags to define the data in the Chart component the following error appears in the console once the Vue project is started.
<chart-series-item :name="'India'"
:data="indiaData"
:line-style="'smooth'">
</chart-series-item>
<chart-series-item :name="'World'"
:data="worldData"
:line-style="'smooth'">
</chart-series-item>
<chart-series-item :name="'Haiti'"
:data="haitiData"
:line-style="'smooth'">
</chart-series-item>
Using a definition like the above, we should be able to define Chart's data with no issues.