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
I’d like to suggest a small refactor for the Vue 3 package.
I converted the remaining Options API components to the Composition API in:
packages/vue3/src/head.ts
packages/vue3/src/whenVisible.ts
packages/vue3/src/deferred.ts
There's one remaining mixin with Options Api - packages/vue3/src/remember.ts which I haven't changed because I don't know its usage.
The main reason for this is to make it possible to run the package without the Options API, and to reduce reliance on patterns like getCurrentInstance() / app.config.globalProperties, which will help with future Vue Vapor compatibility (which I hope will be considered when it's released).
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
Uh oh!
There was an error while loading. Please reload this page.
-
I’d like to suggest a small refactor for the Vue 3 package.
I converted the remaining Options API components to the Composition API in:
packages/vue3/src/head.tspackages/vue3/src/whenVisible.tspackages/vue3/src/deferred.tsThere's one remaining mixin with Options Api -
packages/vue3/src/remember.tswhich I haven't changed because I don't know its usage.The main reason for this is to make it possible to run the package without the Options API, and to reduce reliance on patterns like
getCurrentInstance()/app.config.globalProperties, which will help with future Vue Vapor compatibility (which I hope will be considered when it's released).Here is the commit with the changes:
Megarsh@b4219d3
If this looks useful, I can open a PR against the appropriate branch and adjust based on feedback.
Beta Was this translation helpful? Give feedback.
All reactions