{"action":"created","issue":{"url":"https://api.github.com/repos/js-next/react-style/issues/92","labels_url":"https://api.github.com/repos/js-next/react-style/issues/92/labels{/name}","comments_url":"https://api.github.com/repos/js-next/react-style/issues/92/comments","events_url":"https://api.github.com/repos/js-next/react-style/issues/92/events","html_url":"https://github.com/js-next/react-style/issues/92","id":60798580,"number":92,"title":"Invariant Violation: onlyChild must be passed a children with exactly one child.","user":{"login":"ronag","id":3065230,"avatar_url":"https://avatars.githubusercontent.com/u/3065230?v=3","gravatar_id":"","url":"https://api.github.com/users/ronag","html_url":"https://github.com/ronag","followers_url":"https://api.github.com/users/ronag/followers","following_url":"https://api.github.com/users/ronag/following{/other_user}","gists_url":"https://api.github.com/users/ronag/gists{/gist_id}","starred_url":"https://api.github.com/users/ronag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ronag/subscriptions","organizations_url":"https://api.github.com/users/ronag/orgs","repos_url":"https://api.github.com/users/ronag/repos","events_url":"https://api.github.com/users/ronag/events{/privacy}","received_events_url":"https://api.github.com/users/ronag/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-03-12T10:31:29Z","updated_at":"2015-03-12T10:35:30Z","closed_at":null,"body":"When doing server side rendering I get ```Invariant Violation: onlyChild must be passed a children with exactly one child.```\r\n\r\nI'm using 0.4.0.\r\n\r\nThis gives me the error:\r\n\r\n```\r\n\r\n      <DocumentTitle title='Media Asset Manager'>\r\n        <div styles={this.styles.background}>\r\n          <RouteHandler />\r\n        </div>\r\n      </DocumentTitle>\r\n```\r\n\r\nThis doesn't:\r\n\r\n```\r\n      <DocumentTitle title='Media Asset Manager'>\r\n        <div>\r\n          <RouteHandler />\r\n        </div>\r\n      </DocumentTitle>\r\n```\r\n\r\n```\r\nError: Invariant Violation: onlyChild must be passed a children with exactly one child.\r\n    at invariant (/Users/ronagy/GitHub/foo/node_modules/react/lib/invariant.js:42:15)\r\n    at Object.onlyChild [as only] (/Users/ronagy/GitHub/foo/node_modules/react/lib/onlyChild.js:29:44)\r\n    at [object Object].React.createClass.render (/Users/ronagy/GitHub/foo/node_modules/react-document-title/node_modules/react-side-effect/index.js:52:31)\r\n    at [object Object].ReactCompositeComponentMixin._renderValidatedComponent (/Users/ronagy/GitHub/foo/node_modules/react/lib/ReactCompositeComponent.js:1260:34)\r\n    at [object Object].wrapper [as _renderValidatedComponent] (/Users/ronagy/GitHub/foo/node_modules/react/lib/ReactPerf.js:50:21)\r\n    at [object Object].ReactCompositeComponentMixin.mountComponent (/Users/ronagy/GitHub/foo/node_modules/react/lib/ReactCompositeComponent.js:802:14)\r\n    at [object Object].wrapper [as mountComponent] (/Users/ronagy/GitHub/foo/node_modules/react/lib/ReactPerf.js:50:21)\r\n    at [object Object].ReactCompositeComponentMixin.mountComponent (/Users/ronagy/GitHub/foo/node_modules/react/lib/ReactCompositeComponent.js:808:44)\r\n    at [object Object].wrapper [as mountComponent] (/Users/ronagy/GitHub/foo/node_modules/react/lib/ReactPerf.js:50:21)\r\n    at [object Object].ReactCompositeComponentMixin.mountComponent (/Users/ronagy/GitHub/foo/node_modules/react/lib/ReactCompositeComponent.js:808:44)\r\n    at [object Object].wrapper [as mountComponent] (/Users/ronagy/GitHub/foo/node_modules/react/lib/ReactPerf.js:50:21)\r\n    at /Users/ronagy/GitHub/foo/node_modules/react/lib/ReactServerRendering.js:40:38\r\n    at ReactServerRenderingTransaction.Mixin.perform (/Users/ronagy/GitHub/foo/node_modules/react/lib/Transaction.js:134:20)\r\n    at Object.renderToString (/Users/ronagy/GitHub/foo/node_modules/react/lib/ReactServerRendering.js:38:24)\r\n    at getPageHtml (/Users/ronagy/GitHub/foo/src/server/render.js:39:40)\r\n    at Function.<anonymous> (/Users/ronagy/GitHub/foo/src/server/render.js:28:18)```"},"comment":{"url":"https://api.github.com/repos/js-next/react-style/issues/comments/78456465","html_url":"https://github.com/js-next/react-style/issues/92#issuecomment-78456465","issue_url":"https://api.github.com/repos/js-next/react-style/issues/92","id":78456465,"user":{"login":"ronag","id":3065230,"avatar_url":"https://avatars.githubusercontent.com/u/3065230?v=3","gravatar_id":"","url":"https://api.github.com/users/ronag","html_url":"https://github.com/ronag","followers_url":"https://api.github.com/users/ronag/followers","following_url":"https://api.github.com/users/ronag/following{/other_user}","gists_url":"https://api.github.com/users/ronag/gists{/gist_id}","starred_url":"https://api.github.com/users/ronag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ronag/subscriptions","organizations_url":"https://api.github.com/users/ronag/orgs","repos_url":"https://api.github.com/users/ronag/repos","events_url":"https://api.github.com/users/ronag/events{/privacy}","received_events_url":"https://api.github.com/users/ronag/received_events","type":"User","site_admin":false},"created_at":"2015-03-12T10:35:30Z","updated_at":"2015-03-12T10:35:30Z","body":"An array gets passed into ``ònlyChild```not sure why."}}