varifycode

0.3.0 • Public • Published

This project was bootstrapped with Create React App.

varifycode

 npm install varifycode --save-dev

Usage

- context: PropTypes.string,  
    define verification-code's range, defalut:'abcdefghjkmnpqrstuvwxyzABCDEFGHJKLMNPRSTUVWXYZ23456789'

- width: PropTypes.number,
- height: PropTypes.number,

- onChange: PropTypes.func.isRequired,
    make the parent get the generated code,

  ...
  <VarifyCode
    context={'abcdefghjkmnpqrstuvwxyzABCDEFGHJKLMNPRSTUVWXYZ23456789'}   //生成验证码的范围
    width={100} height={30} 
    onChange={(code) => console.log(code)}                      //父级获得验证码
    />

Readme

Keywords

Package Sidebar

Install

npm i varifycode

Weekly Downloads

11

Version

0.3.0

License

MIT

Last publish

Collaborators

  • eatwood