chain-depict/index.js

13 lines
358 B
JavaScript

import { div, pre } from './main.js'
const demo = div.w(128).h(64) //.onclick.stop('click')
demo.textContent = 'Hello world'
console.log('demo', demo)
document.body.appendChild(demo)
document.body.appendChild(div.w(128).h(64).text('Hello world'))
fetch('./index.js').then(res => res.text()).then(text => {
document.body.appendChild(pre.text(text))
})