fix(runtime-vapor): pass vdom components plain object vnode props - #15738
ValentinYoushkevich wants to merge 1 commit into
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the 鈿欙笍 Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
@vue/compiler-core
@vue/compiler-dom
@vue/compiler-sfc
@vue/compiler-ssr
@vue/compiler-vapor
@vue/reactivity
@vue/runtime-core
@vue/runtime-dom
@vue/runtime-vapor
@vue/server-renderer
@vue/shared
vue
@vue/compat
commit: |
Size ReportBundles
Usages
|
Since #15708, a VDOM component rendered by a Vapor parent gets the parent's raw props record as
vnode.props. That record is created withObject.create(null), so VDOM code that callsObject.prototypemethods on it throws. Vuetify'suseProxiedModeldoes exactly this:vm.vnode.props?.hasOwnProperty(prop)(source). Every v-model component built on it (VTextField, VCheckbox, VBtnToggle...) breaks in a Vapor template withTypeError: vm.vnode.props?.hasOwnProperty is not a function(playground).This hands the vnode a plain object copy, the same as before #15708 and as in #13382. The raw record itself stays prototype-less for Vapor.