otp-react-input
v1.0.14
Published
one-time password input component for the web built with React.
Downloads
7
Maintainers
Readme
otp-react-input
one-time password input component for the web built with React.
To install the latest stable version:
npm install --save otp-react-input
Basic usage:
import React from 'react';
import React0tp from 'otp-react-input';
export default const App =()=> {
const handleSend = (v) => {
console.log("Entered OTP is ", v)
}
return (
<React0tp
title="otp"
borderColor="#ccc"
borderWidth="2px"
borderRadius="5px"
width="50px"
height="50px"
hasError={true}
errorText="please enter all fields"
fieldsNumber={4}
handleSend={handleSend}
/>
);
}