{"action":"created","issue":{"url":"https://api.github.com/repos/facebook/react/issues/6556","repository_url":"https://api.github.com/repos/facebook/react","labels_url":"https://api.github.com/repos/facebook/react/issues/6556/labels{/name}","comments_url":"https://api.github.com/repos/facebook/react/issues/6556/comments","events_url":"https://api.github.com/repos/facebook/react/issues/6556/events","html_url":"https://github.com/facebook/react/issues/6556","id":149868915,"number":6556,"title":"Controlled number input doesn't handle e, - and . properly","user":{"login":"dhruska","id":2578537,"avatar_url":"https://avatars.githubusercontent.com/u/2578537?v=3","gravatar_id":"","url":"https://api.github.com/users/dhruska","html_url":"https://github.com/dhruska","followers_url":"https://api.github.com/users/dhruska/followers","following_url":"https://api.github.com/users/dhruska/following{/other_user}","gists_url":"https://api.github.com/users/dhruska/gists{/gist_id}","starred_url":"https://api.github.com/users/dhruska/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dhruska/subscriptions","organizations_url":"https://api.github.com/users/dhruska/orgs","repos_url":"https://api.github.com/users/dhruska/repos","events_url":"https://api.github.com/users/dhruska/events{/privacy}","received_events_url":"https://api.github.com/users/dhruska/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/facebook/react/labels/good%20first%20bug","name":"good first bug","color":"009800"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2016-04-20T19:53:34Z","updated_at":"2016-04-21T09:33:38Z","closed_at":null,"body":"A controlled number input, without a corresponding `setState` function, still allows `e`, `-` and `.` to be entered (and numbers can be inputted afterwards). I could be incorrect but I don't believe this is the desired behavior.\r\n\r\n[Here's a JSFiddle](https://jsfiddle.net/vervujhm/) demonstrating the issue."},"comment":{"url":"https://api.github.com/repos/facebook/react/issues/comments/212830528","html_url":"https://github.com/facebook/react/issues/6556#issuecomment-212830528","issue_url":"https://api.github.com/repos/facebook/react/issues/6556","id":212830528,"user":{"login":"syranide","id":1714255,"avatar_url":"https://avatars.githubusercontent.com/u/1714255?v=3","gravatar_id":"","url":"https://api.github.com/users/syranide","html_url":"https://github.com/syranide","followers_url":"https://api.github.com/users/syranide/followers","following_url":"https://api.github.com/users/syranide/following{/other_user}","gists_url":"https://api.github.com/users/syranide/gists{/gist_id}","starred_url":"https://api.github.com/users/syranide/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/syranide/subscriptions","organizations_url":"https://api.github.com/users/syranide/orgs","repos_url":"https://api.github.com/users/syranide/repos","events_url":"https://api.github.com/users/syranide/events{/privacy}","received_events_url":"https://api.github.com/users/syranide/received_events","type":"User","site_admin":false},"created_at":"2016-04-21T09:33:38Z","updated_at":"2016-04-21T09:33:38Z","body":"I'm pretty sure this is just another case of these special inputs not playing well with being controlled, `-e.` are all part of valid numbers but only specific combinations actually translate to valid numbers. If the content does not translate to a valid number then the reported value is `''` and it acts as if nothing has changed, AFAIK there is no way around this, at all."}}