Failed to parse “4.” to 4
问题 I am working in React-redux and creating a number type field. The event.target.value returns a string, since it is number type editor it must return value as number so I parse the value to number. The problem comes when I try to enter 4.5 . Firstly, when I type 4 it will get parsed into 4 (sting to number). But when the . entered the number 4. get parse into 4 , so I just failed to enter the floating point values. let onChangeText = (value)=> { fieldProps.onChange(parseFloat(value)); } If I