-
Notifications
You must be signed in to change notification settings - Fork 129
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
add labels plugin #78
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it's a good idea to add plugins that only work on outdated versions of chart.js.
Chart.js version 2 is old and if the plugin does not support newer versions it's likely it won't be maintained and its use for new users is verry limited.
They are then better off using the data labels plugin that is already listed
I disagree. I use this plugin for https://noraj.github.io/XSS-classification-model/ and that's the only label plugin that works well with arc labels. I have been stuck with Chart.js 2.9.1 because this is the only plugin working for this use case. I have spent hours trying to upgrade to Chat.js 4, but the issue is not Chat.js but the replacement plugin chartjs-plugin-datalabels doesn't behave properly for arcs. So rather than ChartJS 4 and ugly labels I preferred to stick to ChartJS 2 and emn178/chartjs-plugin-labels waiting for a better plugin working with newer versions of ChartJS. So I think this plugin is worth being listed since it supports unique feature not working for other labels plugins. |
Hi guys, let me jump in this thread, if I may. In principal, I agree with @LeeLenaleee . Doesn't make much sense to publish now a plugin which is clearly unmaintained and not complaint with last 2 major versions of Chart.js. @noraj I know what you meant. In fact, in my library where I'm wrapping Chart.js, the lib is providing both datalabels and labels plugins. But my lib is based currently on Chart.js 4.4.x and the labels plugin is not working with that. And then I have decided, several years ago, when the lib wrapped Chart.js 3, to change the plugin adapting it to new Chart.js version. I didn't create a fork to new repo because I don't have time to maintain it for JS guys, currently the adapted plugin is working with CHart.js 4.4.x. Here you can take/see the code. The code has been a bit updated to better integrate the J2CL/GWT lib (mainly for events) but you can change it as you want.: https://github.com/pepstock-org/Charba/blob/master/src/org/pepstock/charba/client/resources/js/chartjs-plugin-labels.js Feel free to create a repo and maintain it if you want. And here the doc (even if it is for java developers) but you can see the options: https://pepstock-org.github.io/Charba-Wiki/docs/extensions/Labels#options I hope it can help you. |
Awesome Contribution Checklist:
Please Describe Your Addition
An (now old) plugin I used to add labels on my pie charts.