Cleave.js-Input Mask
Cleave.js is a powerful and lightweight javascript library that provides an easy way to format and validate input fields in web forms. It is particularly useful for handling and formatting user input in various formats such as phone numbers, credit card numbers, dates, and more.
Add Package
yarn add cleave.js
Import
import Cleave from 'cleave.js/react'; import "cleave.js/dist/addons/cleave-phone.in";
Remove Package
yarn remove cleave.js [ remove specific package
from package.json ]