0.0.2 • Published 2 years ago
react-auth-input v0.0.2
react-auth-input
A React component for handling authentication code inputs.
Demo
Installation
npm install react-auth-inputyarn add react-auth-inputpnpm add react-auth-inputUsage
import React from 'react';
import AuthInput from 'react-auth-input';
const App = () => {
const handleCodeCompletion = (value: string) => {
console.log('Submitting code', value);
};
return (
<AuthInput
length={6}
type='alphanumeric'
onCodeCompletion={handleCodeCompletion}
/>
);
};Development
pnpm is used for this project.
Using Storybook:
pnpm storybook