artus9033 / chartjs-plugin-dragdata

Draggable data points plugin for Chart.js
MIT License
257 stars 55 forks source link

Import package doesn't work: `Cannot read properties of undefined` #127

Open skyporter opened 9 months ago

skyporter commented 9 months ago

Describe the bug Importing the library (with webpack) throw an error Uncaught TypeError: Cannot read properties of undefined (reading 'Chart')

versions:

To Reproduce

// application.js
import Chart from "chart.js/auto"
import "chartjs-plugin-dragdata"
artus9033 commented 1 day ago

Hi @skyporter, I finally found time to look at this recently but can't reproduce this with a clean Webpack setup, neither using 2.2.5 nor the current master. Could you provide a MRE repo?