chartjs/chartjs-chart-smith

React JS wrapper

dvcorreia opened this issue · 4 comments

Can Chart.smith.js be integrated in to chart.js react wrappers that already exist, like https://github.com/jerairrest/react-chartjs-2 ?

+1

At the time I got it to work, somehow. I had to down version the react-chartjs-2/chart.js dependency:

  "resolutions": {
    "react-chartjs-2/chart.js": "2.7.2"
  },

You can check it here https://github.com/dvcorreia/pocket-vna/blob/master/client/src/components/Content/Graphs/SmithChart.jsx

There's a simple React example in the Docs now https://www.chartjs.org/chartjs-chart-smith/examples

I need to work on updating to the latest Chart.js (v2.9.3) which is likely why you've had to pin react-chartjs-2 to an older version

I've published a new version, v0.3.0 that I quickly tested against chart.js 2.9.3. It looked like it worked with no code changes.

https://www.npmjs.com/package/chartjs-chart-smith/v/0.3.0