-
Notifications
You must be signed in to change notification settings - Fork 11.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Major and Minor grid lines #4933
Comments
@itnassol there is no easy way to add minor grid lines. Is the picture what you are trying to achieve? |
hi there, No that's what I have achieved so far, but between each of the ticks, I really need 10 minor lines |
One option is to generate more lines and then use y axis callback to hide the labels on everything that is not an integer step of the power of 10. Not sure how easy that is off the top of my head. You might need a custom build that changes https://github.com/chartjs/Chart.js/blob/master/src/core/core.ticks.js#L100-L142 |
Thank you, Good idea, I will have a play, but Minor and Major ticks would be a good enhancement.. |
Going to close this. In v3 we have functional arguments for the grid line config options. That will allow a config that creates extra grid lines, then styles the major ones in a different way. Example https://www.chartjs.org/samples/master/scales/gridlines-scriptable.html |
Got a 404, https://www.chartjs.org/samples/master/scales/gridlines-scriptable.html not found. |
Up to date versioned link so it wont die: https://www.chartjs.org/docs/3.7.0/samples/scale-options/grid.html |
I have created a resistivity chart, and it pulls data from a MySQL databse, all look good.
However i need minor grid-lines on the Y-Axis, (So horizontally).
Any pointers would be good..
The text was updated successfully, but these errors were encountered: