0.0.4 • Published 2 years ago

otp-input-simple v0.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

Getting Started Simple OTP Input

Installation

In the project directory, you can run:

npm i otp-input-simple

Import

import OTPInput from "otp-input-simple";

Example

<OTPInput
    onChange={setOTP}
    value={otp}
    numInputs={6}
    seperator="-"
/>

Props

onChange: onChange function return a value value: input value numInputs: Number of inputs inputStyle: style for input field eg: inputStyle={{ borderRadius: "25%", width: "50px", height: "50px", fontSize: "32px" }} containerStyle: style for container eg: containerStyle={{ display: "flex", justifyContent: "center" }} seperator: field seperator