1.0.0 • Published 3 years ago

itqgj v1.0.0

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

##安装

npm install itqgj

##导入

const itqgj =require('itqgj')

##格式化时间函数使用

<!--调用 dateFormat 对时间进行 行格式化 -->
const newdata = itqgj.dataFormat(new Date())
<!-- 结果   2020-04-0317:20:58 -->
console.log(newdata);

##转义HTML中的特殊字符 ···

const htmlstr = '这是h1标签123'

const str = m.htmlEscape(htmlstr)

console.log(str);

···

##还原HTML中的特殊字符 ···

const str1 = m.htmlUnEscape(str)

console.log(str1);

···

##开源协议

ISC