Skip to content

afeiship/next-dom-create

Repository files navigation

next-dom-create

Dom create for next.

version license size download

installation

npm install -S @jswork/next-dom-create

apis

api params description
element type,props, children Create element node.
text value Create text node.
fragment children Create fragment node.

usage

import NxDomCreate from '@jswork/next-dom-create';

NxDomCreate.element(
  'div',
  { id: '1', style: 'color: red; font-size: 12px;' },
  'hello world.'
);

// <div id="1" style="color: red; font-size: 12px;">hello world.</div>

license

Code released under the MIT license.