jerosoler / Drawflow

Simple flow library 🖥️🖱️
https://jerosoler.github.io/Drawflow/
MIT License
4.7k stars 728 forks source link

vue instance manually destroy #697

Open Hironari-Saito opened 1 year ago

Hironari-Saito commented 1 year ago

Please see #696

jerosoler commented 1 year ago

I see that there would still be a memory leak when removing a node, since it would not be destroyed.

Is it possible to put in the unmount of the component the destruction of the instance?

Hironari-Saito commented 1 year ago

Hi! @jerosoler Thank you for your reply! Your observation is correct.

Not only the clear function, but also the removeNodeId function needs to be individually destroyed. Please wait a moment while I fix the code.

Hironari-Saito commented 1 year ago

I have made some modifications to the code. Please review it!

I have added and tested scenarios for the memory leak in removeNodeId in the PoC repository.