eduardoborges / use-mask-input

✏️ A react Hook for build elegant input masks. Compatible with React Hook Form

Home Page:https://npmjs.com/package/use-mask-input

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Accessing unmasked value from event

RHarryH opened this issue · comments

Does the library support accesing unmasked value from event target? I have put onChange event on form tag to get any form change and event.target.value shows value with mask applied. My workaround to that is the code below but maybe library already allows that without accesing inputmask.

if (target.inputmask) {
    value = target.inputmask.unmaskedvalue()
}