props of vnode didn't initialize
Version
3.1.2
Reproduction link
https://codesandbox.io/s/boring-hofstadter-h2jee
Steps to reproduce
Hi, please look at the console.
What is expected?
It's expected to get merged props, like
{
"aBC": "a-b-c",
"a1": "a1",
"b2": "b2",
"c3": "c3",
}
What is actually happening?
The props of vnode didn't convert to camel case, and there's no default props, such as a1
b2
c3
.
duplicate of https://github.com/vuejs/vue-next/issues/3953
duplicate of #3953
@edison1105 Sorry, I didn't want to mention undefined attrs are not being passed
, so I changed the description. I give all type.props a default value.
How can the props convert to camel case automatically? Like a-b-c
to aBC
. And is there any way to merge type.props to props?
is this what you want: https://codesandbox.io/s/frosty-flower-21wge?file=/src/components/HelloWorld.vue I'm a bit confused about your feature.
is this what you want: https://codesandbox.io/s/frosty-flower-21wge?file=/src/components/HelloWorld.vue I'm a bit confused about your feature.
Yes, I mean this. It's the same value of props in setup. But I wonder why they are different.
This is the link that I got props in setup. https://codesandbox.io/s/competent-chatterjee-y5ipx?file=/src/components/HelloWorld.vue