html5-tag
A simple utility for creating HTML tags.
Installation
npm install --save html5-tag
Usage
; // No end tags for void elements (https://www.w3.org/TR/html5/syntax.html#void-elements);// → '<br>' ;// → '<a href="http://example.com">Example</a>' ;// → '<input name="name" value="Input your name..." disabled>' ;// → '<div title="'"&<>"><i class="icon icon-folder"></i></div>' // Defaults to 'div' if tag is not specified;// → '<div class="container">container text</div>'
License
Copyright (c) 2016 Cheton Wu
Licensed under the MIT License.