Here is my codesandbox where I tried some experiments.
I just wanted to see if I can make the input accept any number between 0 and 255 and block the user's input whenever they're typing something that would result in an invalid value.
As you can see in the codesandbox, I've tried 3 different ways and they all fail to behave as desired in their own unique ways.
Here is my codesandbox where I tried some experiments.
I just wanted to see if I can make the input accept any number between 0 and 255 and block the user's input whenever they're typing something that would result in an invalid value.
As you can see in the codesandbox, I've tried 3 different ways and they all fail to behave as desired in their own unique ways.