watch seems to not work when i have two inputs and the help text is wrong it shows 0 characters #7668
-
hi i am trying to add an error if user goes above character limits in text field, it seems as thought the first text field works when i copy and paste too much text into it but the second field does not <TextField ` Textfield is `export const TextField: React.FC = ({ return ( |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 11 replies
-
can you plz reproduce that in a codesandbox? |
Beta Was this translation helpful? Give feedback.
-
it's not watching lag one render behind, validate function will also be updated in the render function. so if you want to have precise count down on the text, the error message needs to be put inside the render instead of the validate function. |
Beta Was this translation helpful? Give feedback.
it's not watching lag one render behind, validate function will also be updated in the render function. so if you want to have precise count down on the text, the error message needs to be put inside the render instead of the validate function.