1.0.0 • Published 4 years ago
enzo21otp v1.0.0
react-native-otp-form
React Native component for OTP Input Form

Getting started
yarn add react-native-otp-form
or
npm install react-native-otp-form --save
Usage
Example
import {OTP} from 'react-native-otp-form'; <OTP
codeCount={6}
containerStyle={{marginTop: 50}}
otpStyles={{backgroundColor: '#eee'}}
/>Check out the example project for more examples.
Props
| Type | Required | Description |
|---|---|---|
| codeCount | Yes | How many otp box/character |
| containerStyle | No | Styles for container View |
| otpStyle | No | Styles for each box TextInput |
| onTyping | No | Callback to get otp when user typing |
| onFinish | No | Callback to get otp value when user finish filled all boxes |
Running the Example app
While developing, you can run the example app to test your changes.
Setup
- Clone the repository
- Go to Example folder
- Run
yarn install
Start the app
- Run
yarn androidto run on Android - Run
yarn iosto run on iOS
TODO
- XXXX
- XXXX
License
The library is released under the MIT licence. For more information see LICENSE.
1.0.0
4 years ago