visx icon indicating copy to clipboard operation
visx copied to clipboard

[xychart] make react-spring optional dependency

Open sachinraja opened this issue 2 years ago • 3 comments

I don't use any of the Animated components in my Chart, so I do not want to install @react-spring/web, which gives me a ton of errors with React 18. Could we change the xychart package so the animated components are exported from a separate entry point and @react-spring/web and @visx/react-spring are declared as optional peer dependencies?

sachinraja avatar Jul 05 '22 19:07 sachinraja

Yup, this is a great idea. When we first published the package I think I spent some time trying to do just this but hit some issues. I can try and take a look this week but if anyone else wants to take a shot I'm happy to 👀 a PR as well 🙏

williaster avatar Jul 05 '22 22:07 williaster

Noting this would likely be a breaking change for this package

williaster avatar Jul 05 '22 22:07 williaster

@williaster Do you have any updates on this?

minut-shan avatar May 11 '23 06:05 minut-shan