修复attribute不生效的bug

pull/1/head
yutent 2023-03-13 18:40:57 +08:00
parent aa62c3f5b6
commit 8c3ff7d6ce
1 changed files with 4 additions and 0 deletions

View File

@ -141,6 +141,10 @@ export class Component extends HTMLElement {
[__prop2attr__](name, value) { [__prop2attr__](name, value) {
let options = this.#getPropOptions(name) let options = this.#getPropOptions(name)
if (options.attribute === false) {
return
}
switch (options.type) { switch (options.type) {
case Number: case Number:
case String: case String: