You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

captcha-captcha

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

captcha-captcha

验证码

1.0.4
latest
npmnpm
Version published
Weekly downloads
3
Maintainers
1
Weekly downloads
 
Created
Source

⭐️ 验证码小物件 - 下载

npm i captcha -S

🌰 验证码小物件 - 使用

const captcha = require('captcha')
let temp = captcha.create(fontFamily,color,backgroundColor)
console.log(temp) // {text:'D3DS', data: '<svg></svg>'}

🌰 验证码小物件 - 结合HTTP模块

const http = require('http')
const captcha = require('captcha')

http.createServer((req, res) => {
    res.setHeader('content-type', 'text/html;charset=utf-8')
    let temp = captcha.create(fontFamily,color,backgroundColor) //字体样式,字体颜色,背景颜色
    // console.log(temp) // {text:'D3DS', data: '<svg></svg>'}
    res.end(temp.data)
}).listen(3000, () => {
    console.log('启动成功, 访问  http://localhost:3000');
})

Keywords

svg-captcha

FAQs

Package last updated on 07 Jun 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.