README
🔐 react-confirmation-code-input
One input for every code
📦 How to use?
- Install package using your favourite tool.
yarn i react-confirmation-code-input
npm i react-confirmation-code-input --save
- Import ConfirmationCodeInput from this package
import { ConfirmationCodeInput } from 'react-confirmation-code-input';
🔧 Props
| Property | Type | Description |
|---|---|---|
| fields | number | The number of chars in the code. |
| value | string | Sets the value of the input. |
| onChange | func | Called when user changes value of the input. |
| className | string | Sets CSS class of root element. |
| disabled | bool | Makes all children disabled. |
| regex | string | Makes sure all chars typed are creating matching string |
📝 License
Licensed under the MIT License.