🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
45.64k
stars
8k
forks
source link
Custom Web Elements/Components receive `undefined` instead of `false` on subsequent re-render #11276
Open
Maxim-Mazurok opened 3 days ago
Vue version
3.4.31
Link to minimal reproduction
https://jsfiddle.net/uwegz5y8/23/
Steps to reproduce
Boo: false; typeof: boolean
- as expected, becauseboo
attribute is not setBoo: true; typeof: boolean
- as expected, because nowboo
attribute is setBoo: ; typeof: undefined
- unexpected, sinceboo
attribute is removed - we expect to receivefalse
just like in the 2nd step previouslyWhat is expected?
false
What is actually happening?
undefined
System Info
No response
Any additional comments?
This is similar to https://github.com/vuejs/core/issues/10324, which was not actually a duplicate of #9006
https://github.com/vuejs/core/commit/b49306adff4572d90a42ccd231387f16eb966bbe didn't fix the issue. All it did was to change
null
toundefined
in the 6th step of the original issue reproduction.Kinda related to #9697