♻️ remove csso dependency

do a custom css optimization instead
This commit is contained in:
platane
2022-11-03 08:25:35 +01:00
committed by Platane
parent f83b9ab0c3
commit b40f17a02e
10 changed files with 654 additions and 611 deletions

View File

@@ -0,0 +1,8 @@
export const h = (element: string, attributes: any) =>
`<${element} ${toAttribute(attributes)}/>`;
export const toAttribute = (o: any) =>
Object.entries(o)
.filter(([, value]) => value !== null)
.map(([name, value]) => `${name}="${value}"`)
.join(" ");