初次提交

This commit is contained in:
2021-11-15 16:25:49 +08:00
parent 43ef43b849
commit f5eb42da7e
8 changed files with 272 additions and 1 deletions

View File

@ -1,3 +1,21 @@
# yizhi-html-escape
HTML转义字符处理工具
A HTML escape character util. (>_<)
# Usage
```javascript
import {escape, unescape} from 'yizhi-html-escape'
escape('<div>Tom&Jerry</div>')
//Output:
// &lt;div&gt;Tom&amp;Jerry&lt;/div&gt;
unescape('&pi;=3.14, &yen;&cent;&pound;&copy;&reg;')
//Output
// π=3.14, ¥¢£©®
```