{"action":"created","issue":{"url":"https://api.github.com/repos/mozilla-services/react-jsonschema-form/issues/329","repository_url":"https://api.github.com/repos/mozilla-services/react-jsonschema-form","labels_url":"https://api.github.com/repos/mozilla-services/react-jsonschema-form/issues/329/labels{/name}","comments_url":"https://api.github.com/repos/mozilla-services/react-jsonschema-form/issues/329/comments","events_url":"https://api.github.com/repos/mozilla-services/react-jsonschema-form/issues/329/events","html_url":"https://github.com/mozilla-services/react-jsonschema-form/pull/329","id":179004000,"number":329,"title":"Initial implementation of nullable type","user":{"login":"ohde","id":6856263,"avatar_url":"https://avatars.githubusercontent.com/u/6856263?v=3","gravatar_id":"","url":"https://api.github.com/users/ohde","html_url":"https://github.com/ohde","followers_url":"https://api.github.com/users/ohde/followers","following_url":"https://api.github.com/users/ohde/following{/other_user}","gists_url":"https://api.github.com/users/ohde/gists{/gist_id}","starred_url":"https://api.github.com/users/ohde/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ohde/subscriptions","organizations_url":"https://api.github.com/users/ohde/orgs","repos_url":"https://api.github.com/users/ohde/repos","events_url":"https://api.github.com/users/ohde/events{/privacy}","received_events_url":"https://api.github.com/users/ohde/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-09-24T01:43:26Z","updated_at":"2016-11-25T08:44:00Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/mozilla-services/react-jsonschema-form/pulls/329","html_url":"https://github.com/mozilla-services/react-jsonschema-form/pull/329","diff_url":"https://github.com/mozilla-services/react-jsonschema-form/pull/329.diff","patch_url":"https://github.com/mozilla-services/react-jsonschema-form/pull/329.patch"},"body":"Addresses #282 \n\n![nullabletype](https://cloud.githubusercontent.com/assets/6856263/18805257/0711b95c-81bd-11e6-8d00-ef6739d00180.png)\n\nNote: I had issues implementing HOC for nullable types, it was forcing loss of focus in inputs. Therefore, I used down and dirty Parent -> Child solution to implement nullable type. \n"},"comment":{"url":"https://api.github.com/repos/mozilla-services/react-jsonschema-form/issues/comments/262906910","html_url":"https://github.com/mozilla-services/react-jsonschema-form/pull/329#issuecomment-262906910","issue_url":"https://api.github.com/repos/mozilla-services/react-jsonschema-form/issues/329","id":262906910,"user":{"login":"crumblix","id":6656707,"avatar_url":"https://avatars.githubusercontent.com/u/6656707?v=3","gravatar_id":"","url":"https://api.github.com/users/crumblix","html_url":"https://github.com/crumblix","followers_url":"https://api.github.com/users/crumblix/followers","following_url":"https://api.github.com/users/crumblix/following{/other_user}","gists_url":"https://api.github.com/users/crumblix/gists{/gist_id}","starred_url":"https://api.github.com/users/crumblix/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/crumblix/subscriptions","organizations_url":"https://api.github.com/users/crumblix/orgs","repos_url":"https://api.github.com/users/crumblix/repos","events_url":"https://api.github.com/users/crumblix/events{/privacy}","received_events_url":"https://api.github.com/users/crumblix/received_events","type":"User","site_admin":false},"created_at":"2016-11-25T08:44:00Z","updated_at":"2016-11-25T08:44:00Z","body":"You might want to see issue https://github.com/mozilla-services/react-jsonschema-form/issues/402#issuecomment-262696104\r\nand also https://github.com/mozilla-services/react-jsonschema-form/issues/410\r\n\r\nThe last one is mine.  I'm an advocate of turning \"empty string\" and \"empty array\" into undefined.\r\nThe string and array items are removed from the JSON data ... in the same way that they dissapear from the data for numbers and dates currently.\r\n\r\nThis allows them to pass or fail validation when setting the \"required\" field.  I personally plan to treat them as NULL in my backend and effectively disallow empty string (no loss for me).\r\n\r\nJust throwing this out there in case it meets your requirements without adding a new nullable type :)\r\n\r\nThe array part of the patch has been submitted as a PR:\r\n\r\nhttps://github.com/mozilla-services/react-jsonschema-form/pull/420\r\n\r\nThe string part is referenced in my issue here: https://github.com/mozilla-services/react-jsonschema-form/issues/410\r\nbut hasn't (and won't) be submitted as a PR until Issue #402 is decided upon.\r\n\r\nHope that helps!"}}
{"actor":{"display_login":"crumblix"}}