text-mask-collection
Repository of pre-made input masks
To be used with text-mask with support for Vanilla, Vue, Angular, React and more.
Usage with Vue
The plugin exposes three properties $mask
, $unmask
and $format
with functions mask/unmask and transform according each respective mask.
;;; Vue; Vue; template: ` <div>Value: {{$format.centimeters(rawValue)}}</div> <m-input :value="rawValue" :mask="$mask.centimeters" @input="rawValue = $unmask.centimeters($event) /> ` { return rawValue: 100 };