2.0.1 • Published 2 years ago
mxh v2.0.1
验证码 ⭐ 下载
npm i mxh -S
验证码 ⭐ 使用
const captch = require('mxh')
let data = captch.create()
console.log(data)
验证码 结合http模块
const http = require('http') const captcha = require('mxh')
http.createServer((req, res) => { res.setHeader('content-type', 'text/html;charset=utf-8') let temp = captcha.create() res.end(temp.data) }).listen(3000, () => { console.log('启动成功, 访问 http://localhost:3000'); })