chart-js-rs
chart-js-rs copied to clipboard
Add suport for line chart
This PR add support to plot line chart. Add example for line chart.
Thanks for contributing!
Line charts are available by leveraging scatter plots, can you explain how this is different? I don't want to add extra chart types if they can be done with the existing set.
It might be worth me adding a line example to the code using the scatter plot code, I would be happy to do that if this isn't merged.
Hi there!
As far as I understand to use Scatter instead of Line chart we need to be able to set showLine: true, but currently I don't see this property.
The scatter chart supports all the same properties as the line chart. By default, the scatter chart will override the showLine property of the line chart to false.
And in general, it could work just by setting r#type: "line", but it's not possible ofc due to private types and it makes sense. But would be nice to have wrapper for Line charts or add showLine config at least
Hi @DDtKey!
I've added a line chart to the examples, please let me know if this is not suitable for your use case/doesn't answer your question.
Thanks @Billy-Sheppard, it works as expected to me