Inputmask icon indicating copy to clipboard operation
Inputmask copied to clipboard

Slow performance with numeric digits parameter set

Open kamilpinas opened this issue 2 years ago • 0 comments

I have configured mask on my own currency input component. I have one view where i need to use around 70-100 inputs in one page. I debugged all props from the library and i have seen that digits props set to 2 or more is causing the performance problem. -My mask looks like this:

Inputmask({
            alias: 'currency',
            groupSeparator: '',
            SetMaxOnOverflow: true,
            max: max,
            min: min,
            digits: 2,
            rightAlign: false,
            positionCaretOnClick: 'none',
        }).mask(inputRef.current);

I tried to run mask only onFocus once input at the time but I need to have everywhere the same format with decimals 0.00

  • OS: Windows 11
  • Browser: Google Chrome
  • Inputmask version: 5.0.8-beta.47 but i tested this on 5.0.7 and 5.0.6 too

kamilpinas avatar Jan 31 '23 08:01 kamilpinas