You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Genuinely like curious about this. This is technically a SolidJS component that I'm using for the panels. I'm not sure how it magically persists the SolidJS state in there even when it unmounts/mounts the same component from the DOM, when I switch tabs.
dockview-how.mp4
The usual technique to persist state even after unmounting/mounting a component is to lift the state up a component tree.
I know I'm just using dockview-core for this, and not completely SolidJS so there's no component tree in terms of the dock view, but is the component actually being removed from the DOM at all? Because it seems like it does for me.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Genuinely like curious about this. This is technically a SolidJS component that I'm using for the panels. I'm not sure how it magically persists the SolidJS state in there even when it unmounts/mounts the same component from the DOM, when I switch tabs.
dockview-how.mp4
The usual technique to persist state even after unmounting/mounting a component is to lift the state up a component tree.
I know I'm just using
dockview-core
for this, and not completely SolidJS so there's no component tree in terms of the dock view, but is the component actually being removed from the DOM at all? Because it seems like it does for me.Can someone explain the magic?
Beta Was this translation helpful? Give feedback.
All reactions