generate styles dynamically with universal reactivity, test for conflicting state names

This commit is contained in:
metacryst
2024-03-30 19:43:19 -05:00
parent 997a151b44
commit bf3650ef6a
2 changed files with 102 additions and 99 deletions

View File

@@ -277,4 +277,20 @@ window.testSuites.push( class testInit {
}
}
}
ConflictingPropertyNameThrowsError() {
register(class SidebarFile extends Shadow {
$width = 0
}, randomName("sb-file"))
try {
SidebarFile()
return "Did not throw error!"
} catch(e) {
if(!e.message.includes(`Property name "width" is not valid`)) {
throw e
}
}
}
})