{"action":"created","issue":{"url":"https://api.github.com/repos/styled-components/styled-components/issues/2134","repository_url":"https://api.github.com/repos/styled-components/styled-components","labels_url":"https://api.github.com/repos/styled-components/styled-components/issues/2134/labels{/name}","comments_url":"https://api.github.com/repos/styled-components/styled-components/issues/2134/comments","events_url":"https://api.github.com/repos/styled-components/styled-components/issues/2134/events","html_url":"https://github.com/styled-components/styled-components/issues/2134","id":372406496,"node_id":"MDU6SXNzdWUzNzI0MDY0OTY=","number":2134,"title":"createGlobalStyle does not work with next.js 7 when deployed to now","user":{"login":"brianlovin","id":1923260,"node_id":"MDQ6VXNlcjE5MjMyNjA=","avatar_url":"https://avatars0.githubusercontent.com/u/1923260?v=4","gravatar_id":"","url":"https://api.github.com/users/brianlovin","html_url":"https://github.com/brianlovin","followers_url":"https://api.github.com/users/brianlovin/followers","following_url":"https://api.github.com/users/brianlovin/following{/other_user}","gists_url":"https://api.github.com/users/brianlovin/gists{/gist_id}","starred_url":"https://api.github.com/users/brianlovin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brianlovin/subscriptions","organizations_url":"https://api.github.com/users/brianlovin/orgs","repos_url":"https://api.github.com/users/brianlovin/repos","events_url":"https://api.github.com/users/brianlovin/events{/privacy}","received_events_url":"https://api.github.com/users/brianlovin/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-10-22T06:25:41Z","updated_at":"2018-10-22T20:33:42Z","closed_at":null,"author_association":"NONE","body":"<!--\r\n🚨HOLD UP PLEASE, BEFORE DELETING THIS TEMPLATE!🚨😁\r\nThank you for contributing and please follow this guide before creating an issue! 🙌\r\n\r\n1. Do you have a usage question?\r\n=============================\r\n- Look for prior or closed issues (but please avoid replying to them if they're old)\r\n- Check the docs: https://www.styled-components.com/docs\r\n- Look for/ask questions on stack overflow: https://stackoverflow.com/questions/ask?tags=styled-components\r\n- Start a thread on our Spectrum help channel: https://spectrum.chat/styled-components/help\r\n\r\n2. Think you found a bug?\r\n=============================\r\n- Consider submitting a PR with a failing test instead\r\n- Use the \"BUG TEMPLATE\" below to report a test\r\n- Don't forget to 👉PROVIDE A REPRODUCTION PLEASE😉 (Codesandbox/Webpackbin links are provided, repositories are ok)\r\n- If you can't provide a reproduction, snippets of code can help, but are incomplete reports\r\n\r\n3. Do you have a feature request?\r\n=============================\r\n- Look for old & closed issues (replying might be ok if they're not too old or have no conclusion)\r\n- Otherwise: Remove the template below and provide thoughtful commentary *and code samples* on what this feature means for your product\r\n\r\nWhat will it allow you to do that you can't do today?\r\nHow will it make current work-arounds straightforward?\r\nWhat potential bugs and edge cases does it help to avoid?\r\nPlease keep it product-centric.\r\n-->\r\n\r\n<!-- BUG TEMPLATE -->\r\n## Environment\r\n<!-- Please run this command inside your project and paste its contents here (it automatically copies to your clipboard) -->\r\n\r\n```sh\r\n## System:\r\n - OS: macOS 10.14.1\r\n - CPU: x64 Intel(R) Core(TM) i7-7920HQ CPU @ 3.10GHz\r\n - Memory: 125.21 MB / 16.00 GB\r\n - Shell: 3.2.57 - /bin/bash\r\n## Binaries:\r\n - Node: 10.6.0 - /usr/local/bin/node\r\n - Yarn: 1.3.2 - /usr/local/bin/yarn\r\n - npm: 6.1.0 - /usr/local/bin/npm\r\n - Watchman: 4.9.0 - /usr/local/bin/watchman\r\n## npmPackages:\r\n - babel-plugin-styled-components: ^1.8.0 => 1.8.0\r\n - styled-components: ^4.0.2 => 4.0.2\r\n```\r\n\r\n## Reproduction\r\n\r\n<!-- If you can't reproduce your bug, make sure to add details on how you've set up your project -->\r\nThis appears to be a problem with deploying a project using next.js v7 + styled-components v4, when the `createGlobalStyle` is used in the `_document.js` file.\r\n\r\n## Steps to reproduce\r\n1. Clone https://github.com/specfm/spec-next/tree/sc-4\r\n2. Checkout `sc-4` branch\r\n3. deploy with `now`\r\n\r\n## Expected Behavior\r\nThe `normalize.js` file which contains the `createGlobalStyle` should be injected into the `<head>` of the document to provide global css reset styles.\r\n\r\n## Actual Behavior\r\nThe `createGlobalStyle` does not inject the global css into the `<head>` when deployed with `now` - about 1/10 of my deploys has it *randomly* work, but most deploys will look like this:\r\n\r\n<img width=\"1438\" alt=\"screenshot 2018-10-21 23 17 27\" src=\"https://user-images.githubusercontent.com/1923260/47279849-64e81500-d588-11e8-8022-d2ea474236d9.png\">\r\n\r\nExpected design is at [spec.fm](https://spec.fm) - the deploy live right now had to be built with `styled-components@3.x`\r\n"},"comment":{"url":"https://api.github.com/repos/styled-components/styled-components/issues/comments/431973952","html_url":"https://github.com/styled-components/styled-components/issues/2134#issuecomment-431973952","issue_url":"https://api.github.com/repos/styled-components/styled-components/issues/2134","id":431973952,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMTk3Mzk1Mg==","user":{"login":"timneutkens","id":6324199,"node_id":"MDQ6VXNlcjYzMjQxOTk=","avatar_url":"https://avatars2.githubusercontent.com/u/6324199?v=4","gravatar_id":"","url":"https://api.github.com/users/timneutkens","html_url":"https://github.com/timneutkens","followers_url":"https://api.github.com/users/timneutkens/followers","following_url":"https://api.github.com/users/timneutkens/following{/other_user}","gists_url":"https://api.github.com/users/timneutkens/gists{/gist_id}","starred_url":"https://api.github.com/users/timneutkens/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timneutkens/subscriptions","organizations_url":"https://api.github.com/users/timneutkens/orgs","repos_url":"https://api.github.com/users/timneutkens/repos","events_url":"https://api.github.com/users/timneutkens/events{/privacy}","received_events_url":"https://api.github.com/users/timneutkens/received_events","type":"User","site_admin":false},"created_at":"2018-10-22T20:33:42Z","updated_at":"2018-10-22T20:33:42Z","author_association":"NONE","body":"I guess adding a comment in `_document.js` of the example makes sense."}}
{"actor":{"display_login":"timneutkens"}}