On he official page https://redux-form.com/6.6.1/examples/fieldlevelvalidation/
On the field "Age" is an example of how Redux-forms wrongly assumes the letter e can be a valid character on keyPress, instead of only allowing numbers.
I have tried the following validations, to exclude the letter e, with no success:
export const onlyNumber = (value) => {
return /^[^e]$|[0123456789]$/i.test(value);
};
What could be a possible successful way of skipping Redux-Forms way of validating and actually being able to make a number-only (with 'e' excluded) field?
It's a feature, the fact that it allows 'e'... Shout out to @iamandrewluca in Github, for replying to my question at: https://github.com/erikras/redux-form/issues/4538
Similar question, and responses / workarounds to forbid the 'e' from showing, in Stack overflow: https://stackoverflow.com/a/31706796/4671932
Documentation: https://html.spec.whatwg.org/multipage/input.html#number-state-(type%3Dnumber)