-
Notifications
You must be signed in to change notification settings - Fork 456
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
[Vue 3] Components compatibility audit #966
Comments
Hi |
Any update on getting storefront-ui working with Vue 3? |
In progress. It is rather a huge change in the code so it takes time. If you like you can help @undercovergod with the refactoring :) |
Can I help ? |
@Kearny please check #1987 . |
We need to test all components to check compatibility with the upcoming version of Vue 3.
MAIN GOALS
vue3
MAIN CHANGES IN VUE3
Documentation of Vue composition API find here
➡️ https://vue-composition-api-rfc.netlify.com/api.html#setup
RFC is here ➡️ https://github.com/vuejs/rfcs/tree/master/active-rfcs
but some of the features are not implemented or changed so be careful
Want to test?
vue3
the instruction ➡️ [WIP] Testing environment for Vue 3 #972
Have some questions? Something is not working, please tell us.
OVERALL ISSUES
mobile-observer.js
- changes inVue.observable()
-> need to change toreactive
Vue.component()
anymore -> need to useresolveComponent
orresolveDynamicComponent
or another solution is requiredfocus.js
,focus-trap.js
,clickOutside.js
$attrs
automatically includes all non-prop related attributes - we don't need model, $listeners -> check out this presentation https://github.com/chrisvfritz/vue-3-trends/blob/master/slides-2019-03-vueconfus.pdf<Teleport>
refs
for direct access to DOM nodes instead of relying onthis.$el
.$on
,$off
and$once
instance methods. Vue instances no longer implement the event emitter interface.COMPONENTS ISSUES
rename custom directives hooks, be careful with
v-bind="$attrs"
this inherits also directivesmore info: https://github.com/vuejs/rfcs/blob/master/active-rfcs/0012-custom-directive-api-change.md
Issues with two-way data binding, removed
model
prop[v-model API Change] more info: https://github.com/vuejs/rfcs/blob/master/active-rfcs/0011-v-model-api-change.md
checked
prop, removemodel
propertyupdate:modelValue
model
, usemodelValue
, $emit with update:modelValuemodel
, usemodelValue
checked
prop, removemodel
propertymodel
modelValue
$event
to$event.target.value
Replace
$listeners
withv-bind="$attrs"
More info: https://github.com/vuejs/rfcs/blob/master/active-rfcs/0008-render-function-api-change.md
$listeners
$listeners
this.$listeners
has been removednow
v-bind="$attrs"
inherit also classes and styles - check if this worksmaybe this will be helpful -> https://github.com/vuejs/rfcs/blob/attr-fallthrough/active-rfcs/0000-attr-fallthrough.md
replace
$on
,$off
and$once
methods, proposition is to use the external librarymitt
see more here: https://github.com/vuejs/rfcs/blob/master/active-rfcs/0020-events-api-change.md
🚨 issue with SimpleBar - causing faling resolving component SfScrollable
🚨 issues with globally registered component
maybe this will be helpful -> vuejs/rfcs#29
import { createApp } from 'vue' createApp().mount({}, '#app')
Issues with
mobile-observer.js
, methodisMobile
is not workingImplement
<Teleport>
$vnode
Issue with dynamic directive argument
v-slot:[name]
🚨Issue with import vue2-leaflet
Issue with with import
hammerjs
Issue with
this.$refs
Change transition to transition-group
Issue with
const observer = new MutationObserver()
[TODO] Test after component fixes
EXAMPLES:
Tested components
ATOMS:
MOLECULES:
ORGANISMS:
The text was updated successfully, but these errors were encountered: