rot

rn-otp-timer

A standalone Otp timer one can easily use.

Showing:

Popularity

Downloads/wk

7

GitHub Stars

7

Maintenance

Last Commit

2mos ago

Contributors

0

Package

Dependencies

0

License

MIT

Type Definitions

Built-In

Tree-Shakeable

Yes?

Categories

Readme

rn-otp-timer

A standalone , fully customizable Otp timer you can easily use.

Installation

npm install rn-otp-timer

Usage

import RnOtpTimer from 'rn-otp-timer';

<RnOtpTimer
  minutes={0}
  seconds={40}
  resendButtonStyle={styles.button}
  resendButtonTextStyle={styles.buttonText}
  resendButtonAction={() => {
    console.log('otp resent!');
  }}
/>;

Parameters

ParameterRequiredDescription
minutesNoNumber of minutes for which the timer must be set
secondsNoNumber of seconds for which the timer must be set
resendButtonTextNoSet resend button text content
resendButtonActionYesCallback when resend button is clicked
timerStyleNoProps for styling timer content
resendButtonStyleYesProps for styling resend button
resendButtonTextStyleYesProps for styling resend button text

Development workflow

To get started with the project, run yarn in the root directory to install the required dependencies for each package:

yarn

While it's possible to use npm, the tooling is built around yarn, so you'll have an easier time if you use yarn for development.

While developing, you can run the example app to test your changes.

To run the example app on Android, go to example app directory and run:

yarn android

Contributing

Pull requests are welcome . For major changes, please open an issue first to discuss what you would like to change.

License

MIT

Credits

react-native-bob-builder

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100