core
core copied to clipboard
feat: add `pause/resume` methods for `render` function
fixed #5386
To address the issue of KeepAlive repeatedly executing the effect in the deactivate state, I have added pause and resume methods to ReactiveEffect for pausing and resuming the execution of the effect. Currently, it is used in the KeepAlive component. When the component is in the deactivated state, it pauses the execution of the effect and keeps track of whether it was called during the pause. When the component is in the activated state, it resumes the execution of the effect and immediately executes it once if the run function was called during the pause.