Files
topos/node_modules/style-mod/test/test.html

18 lines
406 B
HTML

<!doctype html>
<meta charset=utf8>
<script>var exports = {}</script>
<script src="../dist/style-mod.js"></script>
<p>Hello</p>
<script>
let mod = new StyleModule({
one: {color: "green"},
two: {textDecoration: "underline",
"&:hover": {textDecoration: "overline"}}
})
StyleModule.mount(document, mod)
document.body.className = mod.one
document.querySelector("p").className = mod.two
</script>