Closed soruban closed 1 year ago
The onValueChange is only called when the value is changed, either by user input, any prop change or on blur (like removing leading 0 if user typed something like 00100
). In this example try typing 0s in front, and then do a blur. You will see it onValueChanged will be called.
If you want to do something onBlur, you can assign event on blur.
Describe the issue and the actual behavior
The docs https://s-yadav.github.io/react-number-format/docs/quirks#notes-and-quirks mention that onValueChanged will be called on Blur but it is not.
Describe the expected behavior
onValueChanged not called onBlur
Provide a CodeSandbox link illustrating the issue
https://codesandbox.io/s/custom-numeric-format-forked-z97sl3?file=/src/App.js
Provide steps to reproduce this issue
Click on the input box, click out, the log statement won't be triggered.
Please check the browsers where the issue is seen