{"action":"created","issue":{"url":"https://api.github.com/repos/chenglou/react-radio-group/issues/12","labels_url":"https://api.github.com/repos/chenglou/react-radio-group/issues/12/labels{/name}","comments_url":"https://api.github.com/repos/chenglou/react-radio-group/issues/12/comments","events_url":"https://api.github.com/repos/chenglou/react-radio-group/issues/12/events","html_url":"https://github.com/chenglou/react-radio-group/issues/12","id":94333777,"number":12,"title":"Not wipe out DOM when changing values?","user":{"login":"iest","id":1926464,"avatar_url":"https://avatars.githubusercontent.com/u/1926464?v=3","gravatar_id":"","url":"https://api.github.com/users/iest","html_url":"https://github.com/iest","followers_url":"https://api.github.com/users/iest/followers","following_url":"https://api.github.com/users/iest/following{/other_user}","gists_url":"https://api.github.com/users/iest/gists{/gist_id}","starred_url":"https://api.github.com/users/iest/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iest/subscriptions","organizations_url":"https://api.github.com/users/iest/orgs","repos_url":"https://api.github.com/users/iest/repos","events_url":"https://api.github.com/users/iest/events{/privacy}","received_events_url":"https://api.github.com/users/iest/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":11,"created_at":"2015-07-10T15:50:46Z","updated_at":"2015-09-29T22:16:52Z","closed_at":null,"body":"Firstly, great idea! Love it.\r\n\r\nHowever, when changing values, React completely wipes out the DOM inside the `radio` components. This is not ideal when wanting to animate the radio buttons after being checked etc.\r\n\r\nThe best I could come up with (while still keeping the same pattern) was to use `defaultChecked` on the inputs instead of `checked`, and make `shouldComponentUpdate` inside the parent return `false`. Effectively making it an \"uncontrolled\" component.\r\n\r\nFeel free to close this issue as it's kinda solved — I was just wondering if you had any thoughts how this could be done a little cleaner?"},"comment":{"url":"https://api.github.com/repos/chenglou/react-radio-group/issues/comments/144206878","html_url":"https://github.com/chenglou/react-radio-group/issues/12#issuecomment-144206878","issue_url":"https://api.github.com/repos/chenglou/react-radio-group/issues/12","id":144206878,"user":{"login":"gkop","id":222582,"avatar_url":"https://avatars.githubusercontent.com/u/222582?v=3","gravatar_id":"","url":"https://api.github.com/users/gkop","html_url":"https://github.com/gkop","followers_url":"https://api.github.com/users/gkop/followers","following_url":"https://api.github.com/users/gkop/following{/other_user}","gists_url":"https://api.github.com/users/gkop/gists{/gist_id}","starred_url":"https://api.github.com/users/gkop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gkop/subscriptions","organizations_url":"https://api.github.com/users/gkop/orgs","repos_url":"https://api.github.com/users/gkop/repos","events_url":"https://api.github.com/users/gkop/events{/privacy}","received_events_url":"https://api.github.com/users/gkop/received_events","type":"User","site_admin":false},"created_at":"2015-09-29T22:16:52Z","updated_at":"2015-09-29T22:16:52Z","body":"I am observing now with react-radio-group because the browser focus state resets when choosing a radio option, breaking a11y for my users. @nkbt I wanted to check out your PR https://github.com/chenglou/react-radio-group/pull/13 hoping that this would also my a11y issue, but it doesn't have the lib/ build directory, and it conflicts with master now anyway :/"}}