Skip to content
forked from yeild/jigsaw

滑動驗證碼製作(純前端)

License

Notifications You must be signed in to change notification settings

hikarisakira/jigsaw

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jigsaw

canvas滑动验证码

用法:

  1. 引入jigsaw.js 和 jigsaw.css

jigsaw.init({
  el: document.getElementById('container'),
  onSuccess: function () { ... },
  onFail: function () { ... },
  onRefresh: function () { ... }
})

Tips:

  1. 图片从 https://picsum.photos/ 随机获取,然后用canvas裁剪生成滑块。

  2. 未编译ES6语法,建议使用现代浏览器体验。

  3. 纯前端验证对安全性没意义,因此本项目仅供学习交流,不考虑实用性。

About

滑動驗證碼製作(純前端)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 73.4%
  • CSS 18.3%
  • HTML 8.3%