{"action":"created","issue":{"url":"https://api.github.com/repos/developit/preact/issues/45","repository_url":"https://api.github.com/repos/developit/preact","labels_url":"https://api.github.com/repos/developit/preact/issues/45/labels{/name}","comments_url":"https://api.github.com/repos/developit/preact/issues/45/comments","events_url":"https://api.github.com/repos/developit/preact/issues/45/events","html_url":"https://github.com/developit/preact/issues/45","id":132664025,"number":45,"title":"Rendering props.children without a wrapper","user":{"login":"nightwolfz","id":805022,"avatar_url":"https://avatars.githubusercontent.com/u/805022?v=3","gravatar_id":"","url":"https://api.github.com/users/nightwolfz","html_url":"https://github.com/nightwolfz","followers_url":"https://api.github.com/users/nightwolfz/followers","following_url":"https://api.github.com/users/nightwolfz/following{/other_user}","gists_url":"https://api.github.com/users/nightwolfz/gists{/gist_id}","starred_url":"https://api.github.com/users/nightwolfz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nightwolfz/subscriptions","organizations_url":"https://api.github.com/users/nightwolfz/orgs","repos_url":"https://api.github.com/users/nightwolfz/repos","events_url":"https://api.github.com/users/nightwolfz/events{/privacy}","received_events_url":"https://api.github.com/users/nightwolfz/received_events","type":"User","site_admin":false},"labels":[{"id":258981564,"url":"https://api.github.com/repos/developit/preact/labels/question","name":"question","color":"cc317c","default":true}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-02-10T10:42:34Z","updated_at":"2016-12-13T07:06:14Z","closed_at":"2016-02-15T12:40:07Z","body":"First of all, great job on Preact !\n\nI noticed the following behavior being inconsistent with react unless there's a preact way of doing it.\n\nIt would be nice if we didn't need to wrap props.children with extra div's\n\nExample:\n\n```\nimport { h, render, Component } from 'preact';\n\nclass TestNotOK extends Component {\n    render() {\n        return <h1 style=\"position:absolute; top:0; left:0\">Doh! Test No worky!</h1>\n    }\n}\nclass TestOK extends Component {\n    render() {\n        return <h1 style=\"position:absolute; top:20px; left:0\">Doh! Test OK now!</h1>\n    }\n}\n\nclass ProviderNotOK extends Component {\n    render() {\n        return this.props.children\n    }\n}\n\nclass ProviderOK extends Component {\n    render() {\n        return <div>{this.props.children}</div>\n    }\n}\n\n// This does not work\nrender(<ProviderNotOK>\n    <TestNotOK/>\n</ProviderNotOK>, document.body);\n\n// This works\nrender(<ProviderOK>\n    <TestOK/>\n</ProviderOK>, document.body);\n```\n"},"comment":{"url":"https://api.github.com/repos/developit/preact/issues/comments/266663171","html_url":"https://github.com/developit/preact/issues/45#issuecomment-266663171","issue_url":"https://api.github.com/repos/developit/preact/issues/45","id":266663171,"user":{"login":"NekR","id":1189265,"avatar_url":"https://avatars.githubusercontent.com/u/1189265?v=3","gravatar_id":"","url":"https://api.github.com/users/NekR","html_url":"https://github.com/NekR","followers_url":"https://api.github.com/users/NekR/followers","following_url":"https://api.github.com/users/NekR/following{/other_user}","gists_url":"https://api.github.com/users/NekR/gists{/gist_id}","starred_url":"https://api.github.com/users/NekR/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NekR/subscriptions","organizations_url":"https://api.github.com/users/NekR/orgs","repos_url":"https://api.github.com/users/NekR/repos","events_url":"https://api.github.com/users/NekR/events{/privacy}","received_events_url":"https://api.github.com/users/NekR/received_events","type":"User","site_admin":false},"created_at":"2016-12-13T07:06:14Z","updated_at":"2016-12-13T07:06:14Z","body":"@developit sad thing :-) Would be great to get \"returning arrays\" support."}}
{"actor":{"display_login":"NekR"}}