0.0.3 • Published 4 years ago

etranstring v0.0.3

Weekly downloads
-
License
ISC
Repository
github
Last release
4 years ago

Etranstring

This library is designed to convert HTML strings to HTML code.

Installation

npm i etranstring --save-dev

Connection and Example

import Etranstring from 'etranstring';

const wrapper = new Etranstring('<div class="wrapper main-wrapper"></div>').getRes();
const title = new Etranstring('<h1 class="title">Title</h1>').getRes();

wrapper.appendChild(title);

document.body.appendChild(wrapper);

Basic concepts and conditions

ConditionExample
Write attributes through the symbol: "=="<input type="text"==class="input"==placeholder="Enter your name">
In the "style" attribute, specify properties strictly through the symbol: ";" with a space<span style="color: green; font-size: 14px"></span>

Important

Doesn't support nested tags.

Do not write the following characters in the tag content: >,<,"",’’,

0.0.1

4 years ago

0.0.3

4 years ago

0.0.2

4 years ago

0.0.0

4 years ago