fix???
This commit is contained in:
parent
3cf92ee51e
commit
672168ca0f
2 changed files with 2 additions and 4 deletions
|
@ -69,9 +69,7 @@ const controlledOrUncontrolledGetters = list => list.reduce((res, name) => {
|
||||||
const controlledName = `controlled${camelized}`
|
const controlledName = `controlled${camelized}`
|
||||||
const uncontrolledName = `uncontrolled${camelized}`
|
const uncontrolledName = `uncontrolled${camelized}`
|
||||||
res[name] = function () {
|
res[name] = function () {
|
||||||
console.log(this)
|
return (this.$props[toggle] && this[toggle]) ? this[controlledName] : this[uncontrolledName]
|
||||||
console.log(Object.getOwnPropertyDescriptor(this, toggle))
|
|
||||||
return (Object.getOwnPropertyDescriptor(this, toggle) && this[toggle]) ? this[controlledName] : this[uncontrolledName]
|
|
||||||
}
|
}
|
||||||
return res
|
return res
|
||||||
}, {})
|
}, {})
|
||||||
|
|
|
@ -31,7 +31,7 @@ const controlledOrUncontrolledGetters = list => list.reduce((res, name) => {
|
||||||
const controlledName = `controlled${camelized}`
|
const controlledName = `controlled${camelized}`
|
||||||
const uncontrolledName = `uncontrolled${camelized}`
|
const uncontrolledName = `uncontrolled${camelized}`
|
||||||
res[name] = function () {
|
res[name] = function () {
|
||||||
return (Object.getOwnPropertyDescriptor(this, toggle) && this[toggle]) ? this[controlledName] : this[uncontrolledName]
|
return (this.$props[toggle] && this[toggle]) ? this[controlledName] : this[uncontrolledName]
|
||||||
}
|
}
|
||||||
return res
|
return res
|
||||||
}, {})
|
}, {})
|
||||||
|
|
Loading…
Add table
Reference in a new issue