sangte icon indicating copy to clipboard operation
sangte copied to clipboard

implement preserve & cleanupTimeout

Open velopert opened this issue 2 years ago • 0 comments

By default, state is removed when no component is referencing it. Therefore, state can be lost unexpectedly when the state is used from page A and B, and user redirects the page from A to B.

To fix this issue, these options should be implemented in config.

cleanupTimeout: the state should be removed after this timeout. by default, set this to 1000, preserve: this option will preserve the state even when the state is not referenced from any component.

velopert avatar Jul 17 '23 07:07 velopert