The strange thing is that it works on my web browser when I run it on Firefox using the Metro Bundler, but when I try to do it on an Android phone I get the error: TypeError undefined is not an object (evaluating 'value.replace')
const setMyString = (value) => { let string = value.replace(/\D/g,''); setString(string);}
It seems that this function sets the error.
const [myString, setString] = useState('');<Input value={myString} onChange={e => setMyString(e.target.value)} />
Here's the rest of the relevant code. The error happens when I use the virtual keyboard and enter a number.