Create multiple line charts

This example shows you how to create a multiple-line chart.

Example of expected JSON Format

The JSON is composed of

  • labels for the X-Axis

  • values for the Y-Axis. values is an array, each item is a line of the chart. A line is a key/values object with key for the line's name.

How to build the expected JSON for multiple-line chart

The following example uses a raw SQL query but it could be replaced by a Sequelize / Mongoose query.

Last updated

Was this helpful?