Robin
Robin
I think we need this too ```ts unmounted(target){ vDirectiveScopes.get(target)?.stop() vDirectiveScopes.delete(target) } ```
@romansp We have decided to go with this approach: ```ts const vDirectiveScopes = new WeakMap(); export const vDirective = { mounted(target, binding) { const scope = vDirectiveScopes.get(target) ?? effectScope() vDirectiveScopes.set(target,...
> I'll do it. Let's quickly discuss this. I think we should keep the state 'readonly', but I think we could have a 'cancel/abort' option for `useAsyncState`.
Something like: https://github.com/nuxt/nuxt/pull/32531
if @roydukkey wants to override state, he can use syncRef with his own data ref
> State with this useAsyncState is intentionally not read only. I am not sure about that. > Changing it to be so essentially makes the composable a glorified version of...
> Let's save for instance that I have a `useAsyncState` that returns for me a user's email preferences. These preferences are displayed on a view that allows the user to...
For this usecase you should consider https://vueuse.org/core/useCloned
I think the purpose of `useAsyncState` is to provide a reactive interface to the result of the callback function. This means that it is not beneficial to make the state...
> If `state` were made deeply readonly, what would be the point of the `shallow` option? I opened a related discussion at Nuxt: https://github.com/nuxt/nuxt/issues/33027 I had a chat with Daniel,...