pxb-tools
v1.0.0
Published
提供了格式化时间、HtmlEscape的功能
Downloads
2
Readme
安装
npm install pxb-tools
导入
const tools = require('pxb-tools')
格式化时间
const dtstr = tools.dateFrame(new Date())
console.log(dtstr)
转义html中的特殊字符
const htmlstr = tools.htmlEscape('<h1>我是xxx</h1>')
console.log(htmlstr)
还原html中的特殊字符
const htmlunstr = tools.htmlunEscape(htmlstr)
console.log(htmlunstr)
开源协议
ISC