use-rut
v1.1.1
Published
A React Custom Hook that allows to format and verify Rut (Chilean DNI)
Downloads
5
Maintainers
Readme
useRut hook
A React Custom Hook that allows to format and verify Rut (Chilean DNI).
Installation
npm install use-rut
How to use
...
import useRut from 'use-rut';
function App() {
const [rut, valido, setRut] = useRut();
return (
<div className="App">
<input onChange={(e) => setRut(e.target.value)} value={rut}/>
<h2>{`valido: ${valido}`}</h2>
</div>
);
}
:robot: Author
Carlos Fernández
You can follow me on github
Copyright © 2021 UseRut Hook.