{"action":"created","comment":{"url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments/148783114","pull_request_review_id":74079104,"id":148783114,"diff_hunk":"@@ -112,7 +115,7 @@ html(lang=lang, dir=isRTL ? 'rtl' : 'ltr', class=isFluidWidth ? 'is-fluid-width'\n \t\t\telse\n \t\t\t\tif sectionCss\n \t\t\t\t\tlink(rel='preload' as='style' href=sectionCss)\n-\t\t\n+\n \t\tif shouldUseStylePreloadCommon\n \t\t\tif isRTL\n \t\t\t\tlink(rel='preload' as='style' href=urls['style-rtl.css'])","path":"server/pages/index.jade","position":72,"original_position":72,"commit_id":"d7bce759f0c0fe732da321b73472867488dad944","original_commit_id":"d7bce759f0c0fe732da321b73472867488dad944","user":{"login":"stephanethomas","id":594356,"avatar_url":"https://avatars0.githubusercontent.com/u/594356?v=4","gravatar_id":"","url":"https://api.github.com/users/stephanethomas","html_url":"https://github.com/stephanethomas","followers_url":"https://api.github.com/users/stephanethomas/followers","following_url":"https://api.github.com/users/stephanethomas/following{/other_user}","gists_url":"https://api.github.com/users/stephanethomas/gists{/gist_id}","starred_url":"https://api.github.com/users/stephanethomas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephanethomas/subscriptions","organizations_url":"https://api.github.com/users/stephanethomas/orgs","repos_url":"https://api.github.com/users/stephanethomas/repos","events_url":"https://api.github.com/users/stephanethomas/events{/privacy}","received_events_url":"https://api.github.com/users/stephanethomas/received_events","type":"User","site_admin":false},"body":"Shouldn't we also update that part of the code as well?\r\n\r\nWe have other [`.jade templates`](https://github.com/Automattic/wp-calypso/tree/master/server/pages) that could benefit from this change as far I can see.","created_at":"2017-11-03T13:38:33Z","updated_at":"2017-11-03T13:45:27Z","html_url":"https://github.com/Automattic/wp-calypso/pull/19392#discussion_r148783114","pull_request_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/19392","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments/148783114"},"html":{"href":"https://github.com/Automattic/wp-calypso/pull/19392#discussion_r148783114"},"pull_request":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/19392"}}},"pull_request":{"url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/19392","id":150069588,"html_url":"https://github.com/Automattic/wp-calypso/pull/19392","diff_url":"https://github.com/Automattic/wp-calypso/pull/19392.diff","patch_url":"https://github.com/Automattic/wp-calypso/pull/19392.patch","issue_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/19392","number":19392,"state":"open","locked":false,"title":"Fix incorrect stylesheet order for all non-EN locales","user":{"login":"marekhrabe","id":156676,"avatar_url":"https://avatars3.githubusercontent.com/u/156676?v=4","gravatar_id":"","url":"https://api.github.com/users/marekhrabe","html_url":"https://github.com/marekhrabe","followers_url":"https://api.github.com/users/marekhrabe/followers","following_url":"https://api.github.com/users/marekhrabe/following{/other_user}","gists_url":"https://api.github.com/users/marekhrabe/gists{/gist_id}","starred_url":"https://api.github.com/users/marekhrabe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marekhrabe/subscriptions","organizations_url":"https://api.github.com/users/marekhrabe/orgs","repos_url":"https://api.github.com/users/marekhrabe/repos","events_url":"https://api.github.com/users/marekhrabe/events{/privacy}","received_events_url":"https://api.github.com/users/marekhrabe/received_events","type":"User","site_admin":false},"body":"This PR makes sure that dynamically loaded CSS is always loaded in intended order.\r\n\r\nWe had a bug in our codebase that could cause wrong order of stylesheets. That lead to overriding specific section styles (for example post-editor.css) by the general style.css. It looked like this for example:\r\n \r\n<img width=\"1173\" alt=\"screen shot 2017-11-01 at 14 14 34\" src=\"https://user-images.githubusercontent.com/156676/32320977-f1ace680-bfbf-11e7-9c71-81bafcd0d25a.png\">\r\n\r\nThe bug was race-conditioned and most importantly, was only reproducible in development in all locales other than English and also in production for RTL languages. \r\n\r\nThe biggest problem was that all dynamically loaded stylesheets were appended to the bottom of `<head>`, regardless of needed order. This PR changes it in a way, that new CSS is inserted right after the original `<link rel=\"stylesheet\">` that the new CSS is replacing. This way, we always have general application-wid CSS first and specific section CSS after it.","created_at":"2017-11-01T15:37:20Z","updated_at":"2017-11-03T13:45:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"dcb842eaa28453eca24190719ad0767c04acd002","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/19392/commits","review_comments_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/19392/comments","review_comment_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/19392/comments","statuses_url":"https://api.github.com/repos/Automattic/wp-calypso/statuses/d7bce759f0c0fe732da321b73472867488dad944","head":{"label":"Automattic:fix/stylesheet-ordering-and-language-switching","ref":"fix/stylesheet-ordering-and-language-switching","sha":"d7bce759f0c0fe732da321b73472867488dad944","user":{"login":"Automattic","id":887802,"avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"repo":{"id":45936895,"name":"wp-calypso","full_name":"Automattic/wp-calypso","owner":{"login":"Automattic","id":887802,"avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Automattic/wp-calypso","description":"The new JavaScript- and API-powered WordPress.com","fork":false,"url":"https://api.github.com/repos/Automattic/wp-calypso","forks_url":"https://api.github.com/repos/Automattic/wp-calypso/forks","keys_url":"https://api.github.com/repos/Automattic/wp-calypso/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Automattic/wp-calypso/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Automattic/wp-calypso/teams","hooks_url":"https://api.github.com/repos/Automattic/wp-calypso/hooks","issue_events_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/events{/number}","events_url":"https://api.github.com/repos/Automattic/wp-calypso/events","assignees_url":"https://api.github.com/repos/Automattic/wp-calypso/assignees{/user}","branches_url":"https://api.github.com/repos/Automattic/wp-calypso/branches{/branch}","tags_url":"https://api.github.com/repos/Automattic/wp-calypso/tags","blobs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Automattic/wp-calypso/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/refs{/sha}","trees_url":"https://api.github.com/repos/Automattic/wp-calypso/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Automattic/wp-calypso/statuses/{sha}","languages_url":"https://api.github.com/repos/Automattic/wp-calypso/languages","stargazers_url":"https://api.github.com/repos/Automattic/wp-calypso/stargazers","contributors_url":"https://api.github.com/repos/Automattic/wp-calypso/contributors","subscribers_url":"https://api.github.com/repos/Automattic/wp-calypso/subscribers","subscription_url":"https://api.github.com/repos/Automattic/wp-calypso/subscription","commits_url":"https://api.github.com/repos/Automattic/wp-calypso/commits{/sha}","git_commits_url":"https://api.github.com/repos/Automattic/wp-calypso/git/commits{/sha}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/comments{/number}","issue_comment_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/comments{/number}","contents_url":"https://api.github.com/repos/Automattic/wp-calypso/contents/{+path}","compare_url":"https://api.github.com/repos/Automattic/wp-calypso/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Automattic/wp-calypso/merges","archive_url":"https://api.github.com/repos/Automattic/wp-calypso/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Automattic/wp-calypso/downloads","issues_url":"https://api.github.com/repos/Automattic/wp-calypso/issues{/number}","pulls_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls{/number}","milestones_url":"https://api.github.com/repos/Automattic/wp-calypso/milestones{/number}","notifications_url":"https://api.github.com/repos/Automattic/wp-calypso/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Automattic/wp-calypso/labels{/name}","releases_url":"https://api.github.com/repos/Automattic/wp-calypso/releases{/id}","deployments_url":"https://api.github.com/repos/Automattic/wp-calypso/deployments","created_at":"2015-11-10T20:00:16Z","updated_at":"2017-11-03T12:22:01Z","pushed_at":"2017-11-03T13:34:56Z","git_url":"git://github.com/Automattic/wp-calypso.git","ssh_url":"git@github.com:Automattic/wp-calypso.git","clone_url":"https://github.com/Automattic/wp-calypso.git","svn_url":"https://github.com/Automattic/wp-calypso","homepage":"https://developer.wordpress.com/calypso/","size":77435,"stargazers_count":9384,"watchers_count":9384,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1287,"mirror_url":null,"archived":false,"open_issues_count":2304,"forks":1287,"open_issues":2304,"watchers":9384,"default_branch":"master"}},"base":{"label":"Automattic:master","ref":"master","sha":"2ce1b81d87ff450d8559a7c0af9aa377e0820695","user":{"login":"Automattic","id":887802,"avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"repo":{"id":45936895,"name":"wp-calypso","full_name":"Automattic/wp-calypso","owner":{"login":"Automattic","id":887802,"avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Automattic/wp-calypso","description":"The new JavaScript- and API-powered WordPress.com","fork":false,"url":"https://api.github.com/repos/Automattic/wp-calypso","forks_url":"https://api.github.com/repos/Automattic/wp-calypso/forks","keys_url":"https://api.github.com/repos/Automattic/wp-calypso/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Automattic/wp-calypso/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Automattic/wp-calypso/teams","hooks_url":"https://api.github.com/repos/Automattic/wp-calypso/hooks","issue_events_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/events{/number}","events_url":"https://api.github.com/repos/Automattic/wp-calypso/events","assignees_url":"https://api.github.com/repos/Automattic/wp-calypso/assignees{/user}","branches_url":"https://api.github.com/repos/Automattic/wp-calypso/branches{/branch}","tags_url":"https://api.github.com/repos/Automattic/wp-calypso/tags","blobs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Automattic/wp-calypso/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/refs{/sha}","trees_url":"https://api.github.com/repos/Automattic/wp-calypso/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Automattic/wp-calypso/statuses/{sha}","languages_url":"https://api.github.com/repos/Automattic/wp-calypso/languages","stargazers_url":"https://api.github.com/repos/Automattic/wp-calypso/stargazers","contributors_url":"https://api.github.com/repos/Automattic/wp-calypso/contributors","subscribers_url":"https://api.github.com/repos/Automattic/wp-calypso/subscribers","subscription_url":"https://api.github.com/repos/Automattic/wp-calypso/subscription","commits_url":"https://api.github.com/repos/Automattic/wp-calypso/commits{/sha}","git_commits_url":"https://api.github.com/repos/Automattic/wp-calypso/git/commits{/sha}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/comments{/number}","issue_comment_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/comments{/number}","contents_url":"https://api.github.com/repos/Automattic/wp-calypso/contents/{+path}","compare_url":"https://api.github.com/repos/Automattic/wp-calypso/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Automattic/wp-calypso/merges","archive_url":"https://api.github.com/repos/Automattic/wp-calypso/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Automattic/wp-calypso/downloads","issues_url":"https://api.github.com/repos/Automattic/wp-calypso/issues{/number}","pulls_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls{/number}","milestones_url":"https://api.github.com/repos/Automattic/wp-calypso/milestones{/number}","notifications_url":"https://api.github.com/repos/Automattic/wp-calypso/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Automattic/wp-calypso/labels{/name}","releases_url":"https://api.github.com/repos/Automattic/wp-calypso/releases{/id}","deployments_url":"https://api.github.com/repos/Automattic/wp-calypso/deployments","created_at":"2015-11-10T20:00:16Z","updated_at":"2017-11-03T12:22:01Z","pushed_at":"2017-11-03T13:34:56Z","git_url":"git://github.com/Automattic/wp-calypso.git","ssh_url":"git@github.com:Automattic/wp-calypso.git","clone_url":"https://github.com/Automattic/wp-calypso.git","svn_url":"https://github.com/Automattic/wp-calypso","homepage":"https://developer.wordpress.com/calypso/","size":77435,"stargazers_count":9384,"watchers_count":9384,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1287,"mirror_url":null,"archived":false,"open_issues_count":2304,"forks":1287,"open_issues":2304,"watchers":9384,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/19392"},"html":{"href":"https://github.com/Automattic/wp-calypso/pull/19392"},"issue":{"href":"https://api.github.com/repos/Automattic/wp-calypso/issues/19392"},"comments":{"href":"https://api.github.com/repos/Automattic/wp-calypso/issues/19392/comments"},"review_comments":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/19392/comments"},"review_comment":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/19392/commits"},"statuses":{"href":"https://api.github.com/repos/Automattic/wp-calypso/statuses/d7bce759f0c0fe732da321b73472867488dad944"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"stephanethomas"}}