1.0.3 • Published 2 years ago
svg_zzy123456 v1.0.3
下载
npm i svg_zzy123456 -S
使用 -结合和http使用
const http = require('http')
const svgCaptcha = require('svg_zzy123456')
http.createServer((req,res)=>{
let captcha = svgCaptcha.createSvg()
res.setHeader('content-type','text/html;charset=utf-8')
res.end(captcha.data)
}).listen(3000, ()=>{
console.log('启动成功!请访问:http://localhost:3000');
})
1.0.3
2 years ago