bdom - jsx compatible shorthand tool for creating actual dom elements
installation
npm install bdom
usage
const dom = require('bdom')
const { h1, text, figcaption, style } = dom
const txt = text('BAR')
const title =
h1(
txt,
figcaption( style('background-color: orange; font-size:0.5rem;'), 'a friend of foo' )
)
...and the same by replacing React and in jsx
const dom = require('bdom')
const React = dom
const txt = text('BAR')
const title =
<h1>
{txt}
<figcaption style="background-color: orange; font-size:0.5rem;">a friend of foo</figcaption>
</h1>
tests
npm test
build
npm run build