AnimatedValue Memory Leak
🐛 Bug Report
AnimatedValues are being created but not deleted when using nextjs and SSR.
https://spectrum.chat/react-spring/general/animated-component-is-causing-memory-leak~1190af03-e0c9-4e6d-9d07-1419581424a2 may be relevant.
To Reproduce
Create an AnimatedValue (animated.div) server-side using nextjs.
Expected behavior
The AnimatedValues are properly cleaned up.
Environment
react-spring^v8.0.18react^v16.8.0
The same seems to happen with useTransition. Left a Next.js site with a useTransition carousel (that switches slides every 8 seconds) open overnight, Chrome stopped the site due to out-of-memory exception.
See this image: https://d.pr/i/PO1PYy
This is happening to me also.
Please try with react-spring@next. 👍
If that doesn't work, run @react-spring/envinfo and create a gist with the output like this.
Then paste that link here. Thanks!
Hello there, We have the same issue here. react-spring@next fixed it and I did not see any regression (yet).
Thanks @aleclarson
Hi, is it possible that you still fix this bug in v8? We also have this problem and cannot update to v9beta due to other bugs.
After upgrading to latest v9 version our memory usage stabilized. We've had this memory leak for a long time, and it took a while for us to figure out it was because of this lib.
