I am trying to setup ChartJS with Symfony UX. Since a default datetime adapter is not included with ChartJS 3+, I am getting the following error when using time unit in an axis.
This method is not implemented: Check that a complete date adapter is provided.
How can I add a ChartJS datetime adapter to symfony/ux-chartjs?
I tried importing chartjs-adapter-moment to my app.js, but this adds a second copy of ChartJS module from node_modules/chart.js/dist/chart.mjs to the generated bundle, and registers the adapter to this second copy.
But the symfony ux controller is using its own copy of ChartJS from vendor/symfony/ux-chartjs/assets/node_modules/chart.js/dist/chart.esm.js.
2.29.4and chart.js3.4.1. In myapp.jsI have addedimport 'chartjs-adapter-moment';.