Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Public API: effect without stop #712

Closed
jods4 opened this issue Feb 9, 2020 · 0 comments
Closed

Public API: effect without stop #712

jods4 opened this issue Feb 9, 2020 · 0 comments

Comments

@jods4
Copy link
Contributor

jods4 commented Feb 9, 2020

What problem does this feature solve?

The public API is unusable without creating memory leaks.
effect is exposed:
https://github.com/vuejs/vue-next/blob/master/packages/runtime-core/src/apiReactivity.ts#L12
but stop is not.

What does the proposed API look like?

Either remove effect or expose stop.

Note
The publicly exposed computed and watch are linked the component lifetime when used inside setup (computed is not the one exposed by reactivity but a wrapper).
Without effect, there is no way to do a computed or watch inside setup that is not linked to the component.
I have no use case for that, just noting.

@github-actions github-actions bot locked and limited conversation to collaborators Nov 16, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant