1.0.0 • Published 2 years ago
itheima-toolszzztest v1.0.0
Install
npm install itheima-tools
Import
const itheima = require('itheima-tools')
Date Formation
// 调用dataFormat 进行格式化
const dtStr = itheima.dataFormat(new Date())
console.log(dtStr)
Escaping the Special sub symbol in HTML
const htmlStr = '<h1 title="abc">这是h1标签<span>123 <span></h1>'
const str = itheima.htmlEscape(htmlStr)
console.log(str)
Open source protocol
ISC
1.0.0
2 years ago