Skip to content
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

Outdated version #1540

Closed
malkeet-gwebs opened this issue Nov 21, 2022 · 8 comments · Fixed by #1554
Closed

Outdated version #1540

malkeet-gwebs opened this issue Nov 21, 2022 · 8 comments · Fixed by #1554

Comments

@malkeet-gwebs
Copy link

ng2-charts using outdated version of chart.js please update on urgent basis

@MarcoB1234
Copy link

I get the error below if I run npm list chart.js whilst having ng2-charts version 4.01 and chart.js version 4.01 installed on my node_modules folder (the fact that both versions are 4.0.1 makes you thinks they are supposed to work fine together)

image

@aplongh
Copy link

aplongh commented Nov 22, 2022

Are there any plans of supporting chartjs@4.0.1?

@dangreen
Copy link

@santam85 Hi. I'm Dan from Chart.js team. I want to help you, and I have a suggestion on how to upgrade to Chart.js v4.

Chart.js v4 becomes an ESM-only package, so the wrapper also should become ESM-only. You need to set "type": "module" in package.json - it can cause issues with configs/tools that you also have to solve.

@santam85
Copy link
Contributor

santam85 commented Nov 23, 2022

Hey folks, hope to get around this soon. @dangreen thanks for the suggestion
If anyone needs this in a hurry, consider opening a PR.

@santam85
Copy link
Contributor

@santam85 Hi. I'm Dan from Chart.js team. I want to help you, and I have a suggestion on how to upgrade to Chart.js v4.

Chart.js v4 becomes an ESM-only package, so the wrapper also should become ESM-only. You need to set "type": "module" in package.json - it can cause issues with configs/tools that you also have to solve.

@dangreen I did a first test with 4.0.1 and the library seems to work correctly in general, apart from some defaults resolution issues. Is there any breaking change on how that works in v4? Or any known issue? Seems to be limited to the doughnut/pie controllers...

@dangreen
Copy link

@santam85 The full list of changes is here: https://www.chartjs.org/docs/latest/migration/v4-migration.html

I think there are no more breaking changes important for the wrapper.

@santam85
Copy link
Contributor

Then I think I'm running in either a bug or an undocumented change. Will try to reproduce it in an example.

@santam85
Copy link
Contributor

@dangreen Unless I am missing something obvious, here's the issue that I'm facing. Nothing that blocks the release, but would like to understand if there's something fundamentally wrong with the way I do things in ng2-charts before ignoring the failing visual tests I have in place.

chartjs/Chart.js#10927

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants