itheima-tools-haoyu
v1.0.0
Published
提供了格式化时间、HTMLEscape相关的功能
Readme
安装方式
npm install itheima-tools-haoyu
导入方式
const itheima = require('itheima-tools-haoyu')
格式化时间
const date = new Date()
const newDate = itheima.dateFormat(date)
转义HTML中的特殊字符
const htmlStr = '<h1>nihao</h1>'
console.log(date.htmlEscape(htmlStr))
开源协议
ISC
