Skip to content

Commit

Permalink
complete the first 'getting-started' example (#8829)
Browse files Browse the repository at this point in the history
This page is very likely the first example a new user sees, so we should make it clear how to actually use the config and setup show to actually render a chart.
  • Loading branch information
mjcross committed Apr 6, 2021
1 parent ac0a86b commit b4d118e
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions docs/getting-started/index.md
Expand Up @@ -53,6 +53,19 @@ module.exports = {
};
```

Finally, render the chart using our configuration:

```html
<script>
// === include 'setup' then 'config' above ===
var myChart = new Chart(
document.getElementById('myChart'),
config
);
</script>
```

It's that easy to get started using Chart.js! From here you can explore the many options that can help you customise your charts with scales, tooltips, labels, colors, custom actions, and much more.

All our examples are [available online](https://www.chartjs.org/samples/latest/) but you can also download the `Chart.js.zip` archive attached to every [release](https://github.com/chartjs/Chart.js/releases) to experiment with our samples locally from the `/samples` folder.

0 comments on commit b4d118e

Please sign in to comment.