1.1.0 • Published 1 year ago
test-zxh-tools1 v1.1.0
安装
npm install test-zxh-tools1
导入
const tools =require('test-zxh-tools1')
格式化时间
const date = new Date()
const newDate = tools.dateFormat(date)
console.log(newDate)
html特殊字符转义
const str1 = '<h1 style="color:red">1&2</h1>'
console.log(tools.handleChar1(str1))
html特殊字符转义还原
const str2 = '<h1 style="color:red">1"2</h1>'
console.log(tools.handleChar2(str2))
开源协议
ISC