wiaxy-otp-input
v0.1.0
Published
Beautiful auto-focus OTP input fields with paste support.
Maintainers
Readme
wiaxy-otp-input
A clean, auto-focus OTP input with paste handling — no dependencies.
Install
npm install wiaxy-otp-inputUsage
HTML:
<div id="otp"></div>JS:
import { createOtpInput } from "wiaxy-otp-input";
createOtpInput(document.getElementById("otp"), {
length: 6,
onComplete: code => console.log("OTP:", code)
});Features
✅ Auto move to next input
✅ Backspace jumps backward
✅ Paste support (paste full code)
✅ Works with any CSS (default minimal styles included)
License
MIT
