element-mold

0.0.3 • Public • Published

Element mold

A collection of simple HTML/SVG Element generation functions. Supports typescript!

example

import {section, h1, div, span, b} from 'element-mold/dist/html';

let ref1, ref2;
const refSection = section({className: 'container'}, [
  ref1 = h1('Heading Text'), 
  ref2 = div({className: 'container-body'}, [
    'test',
    span({}, [
      ' text',
      b('bold'),
      ' text',
    ]),
  ]),
]);

console.log(refSection, ref1, ref2);

Package Sidebar

Install

npm i element-mold

Weekly Downloads

1

Version

0.0.3

License

MIT

Unpacked Size

29.2 kB

Total Files

9

Last publish

Collaborators

  • lowfront