{"action":"created","comment":{"url":"https://api.github.com/repos/Khan/aphrodite/pulls/comments/65979083","id":65979083,"diff_hunk":"@@ -23,20 +23,20 @@ export const generateCSS = (selector, styleTypes, stringHandlers,\n         }\n     });\n \n-    return (\n+    return [\n         generateCSSRuleset(selector, declarations, stringHandlers,\n-            useImportant) +\n-        Object.keys(pseudoStyles).map(pseudoSelector => {\n+            useImportant),\n+        ...Object.keys(pseudoStyles).map(pseudoSelector => {","path":"src/generate.js","position":10,"original_position":10,"commit_id":"af72eae994f55fb1afaa56ddcaf6a70ef5a8043c","original_commit_id":"af72eae994f55fb1afaa56ddcaf6a70ef5a8043c","user":{"login":"kentcdodds","id":1500684,"avatar_url":"https://avatars.githubusercontent.com/u/1500684?v=3","gravatar_id":"","url":"https://api.github.com/users/kentcdodds","html_url":"https://github.com/kentcdodds","followers_url":"https://api.github.com/users/kentcdodds/followers","following_url":"https://api.github.com/users/kentcdodds/following{/other_user}","gists_url":"https://api.github.com/users/kentcdodds/gists{/gist_id}","starred_url":"https://api.github.com/users/kentcdodds/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kentcdodds/subscriptions","organizations_url":"https://api.github.com/users/kentcdodds/orgs","repos_url":"https://api.github.com/users/kentcdodds/repos","events_url":"https://api.github.com/users/kentcdodds/events{/privacy}","received_events_url":"https://api.github.com/users/kentcdodds/received_events","type":"User","site_admin":false},"body":"Personally, I feel like this code could be refactored a bit to make it easier to read. Each item in this array should probably be assigned to a variable with a name that describes its purpose and then those could be put into the array as needed...","created_at":"2016-06-06T22:11:15Z","updated_at":"2016-06-06T22:11:15Z","html_url":"https://github.com/Khan/aphrodite/pull/83#discussion_r65979083","pull_request_url":"https://api.github.com/repos/Khan/aphrodite/pulls/83","_links":{"self":{"href":"https://api.github.com/repos/Khan/aphrodite/pulls/comments/65979083"},"html":{"href":"https://github.com/Khan/aphrodite/pull/83#discussion_r65979083"},"pull_request":{"href":"https://api.github.com/repos/Khan/aphrodite/pulls/83"}}},"pull_request":{"url":"https://api.github.com/repos/Khan/aphrodite/pulls/83","id":72768527,"html_url":"https://github.com/Khan/aphrodite/pull/83","diff_url":"https://github.com/Khan/aphrodite/pull/83.diff","patch_url":"https://github.com/Khan/aphrodite/pull/83.patch","issue_url":"https://api.github.com/repos/Khan/aphrodite/issues/83","number":83,"state":"open","locked":false,"title":"Try insertRule","user":{"login":"pvolok","id":2015955,"avatar_url":"https://avatars.githubusercontent.com/u/2015955?v=3","gravatar_id":"","url":"https://api.github.com/users/pvolok","html_url":"https://github.com/pvolok","followers_url":"https://api.github.com/users/pvolok/followers","following_url":"https://api.github.com/users/pvolok/following{/other_user}","gists_url":"https://api.github.com/users/pvolok/gists{/gist_id}","starred_url":"https://api.github.com/users/pvolok/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pvolok/subscriptions","organizations_url":"https://api.github.com/users/pvolok/orgs","repos_url":"https://api.github.com/users/pvolok/repos","events_url":"https://api.github.com/users/pvolok/events{/privacy}","received_events_url":"https://api.github.com/users/pvolok/received_events","type":"User","site_admin":false},"body":"Demonstration of using `styleTag.sheet.insertRule` instead of `styleTag.appendChild` for #76.","created_at":"2016-06-06T20:02:25Z","updated_at":"2016-06-06T22:11:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e43b26692c13ca3c7bcb2dda771210005bb09083","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Khan/aphrodite/pulls/83/commits","review_comments_url":"https://api.github.com/repos/Khan/aphrodite/pulls/83/comments","review_comment_url":"https://api.github.com/repos/Khan/aphrodite/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Khan/aphrodite/issues/83/comments","statuses_url":"https://api.github.com/repos/Khan/aphrodite/statuses/af72eae994f55fb1afaa56ddcaf6a70ef5a8043c","head":{"label":"pvolok:insertRule","ref":"insertRule","sha":"af72eae994f55fb1afaa56ddcaf6a70ef5a8043c","user":{"login":"pvolok","id":2015955,"avatar_url":"https://avatars.githubusercontent.com/u/2015955?v=3","gravatar_id":"","url":"https://api.github.com/users/pvolok","html_url":"https://github.com/pvolok","followers_url":"https://api.github.com/users/pvolok/followers","following_url":"https://api.github.com/users/pvolok/following{/other_user}","gists_url":"https://api.github.com/users/pvolok/gists{/gist_id}","starred_url":"https://api.github.com/users/pvolok/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pvolok/subscriptions","organizations_url":"https://api.github.com/users/pvolok/orgs","repos_url":"https://api.github.com/users/pvolok/repos","events_url":"https://api.github.com/users/pvolok/events{/privacy}","received_events_url":"https://api.github.com/users/pvolok/received_events","type":"User","site_admin":false},"repo":{"id":60156519,"name":"aphrodite","full_name":"pvolok/aphrodite","owner":{"login":"pvolok","id":2015955,"avatar_url":"https://avatars.githubusercontent.com/u/2015955?v=3","gravatar_id":"","url":"https://api.github.com/users/pvolok","html_url":"https://github.com/pvolok","followers_url":"https://api.github.com/users/pvolok/followers","following_url":"https://api.github.com/users/pvolok/following{/other_user}","gists_url":"https://api.github.com/users/pvolok/gists{/gist_id}","starred_url":"https://api.github.com/users/pvolok/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pvolok/subscriptions","organizations_url":"https://api.github.com/users/pvolok/orgs","repos_url":"https://api.github.com/users/pvolok/repos","events_url":"https://api.github.com/users/pvolok/events{/privacy}","received_events_url":"https://api.github.com/users/pvolok/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/pvolok/aphrodite","description":"It's inline styles, but they work!","fork":true,"url":"https://api.github.com/repos/pvolok/aphrodite","forks_url":"https://api.github.com/repos/pvolok/aphrodite/forks","keys_url":"https://api.github.com/repos/pvolok/aphrodite/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pvolok/aphrodite/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pvolok/aphrodite/teams","hooks_url":"https://api.github.com/repos/pvolok/aphrodite/hooks","issue_events_url":"https://api.github.com/repos/pvolok/aphrodite/issues/events{/number}","events_url":"https://api.github.com/repos/pvolok/aphrodite/events","assignees_url":"https://api.github.com/repos/pvolok/aphrodite/assignees{/user}","branches_url":"https://api.github.com/repos/pvolok/aphrodite/branches{/branch}","tags_url":"https://api.github.com/repos/pvolok/aphrodite/tags","blobs_url":"https://api.github.com/repos/pvolok/aphrodite/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pvolok/aphrodite/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pvolok/aphrodite/git/refs{/sha}","trees_url":"https://api.github.com/repos/pvolok/aphrodite/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pvolok/aphrodite/statuses/{sha}","languages_url":"https://api.github.com/repos/pvolok/aphrodite/languages","stargazers_url":"https://api.github.com/repos/pvolok/aphrodite/stargazers","contributors_url":"https://api.github.com/repos/pvolok/aphrodite/contributors","subscribers_url":"https://api.github.com/repos/pvolok/aphrodite/subscribers","subscription_url":"https://api.github.com/repos/pvolok/aphrodite/subscription","commits_url":"https://api.github.com/repos/pvolok/aphrodite/commits{/sha}","git_commits_url":"https://api.github.com/repos/pvolok/aphrodite/git/commits{/sha}","comments_url":"https://api.github.com/repos/pvolok/aphrodite/comments{/number}","issue_comment_url":"https://api.github.com/repos/pvolok/aphrodite/issues/comments{/number}","contents_url":"https://api.github.com/repos/pvolok/aphrodite/contents/{+path}","compare_url":"https://api.github.com/repos/pvolok/aphrodite/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pvolok/aphrodite/merges","archive_url":"https://api.github.com/repos/pvolok/aphrodite/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pvolok/aphrodite/downloads","issues_url":"https://api.github.com/repos/pvolok/aphrodite/issues{/number}","pulls_url":"https://api.github.com/repos/pvolok/aphrodite/pulls{/number}","milestones_url":"https://api.github.com/repos/pvolok/aphrodite/milestones{/number}","notifications_url":"https://api.github.com/repos/pvolok/aphrodite/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pvolok/aphrodite/labels{/name}","releases_url":"https://api.github.com/repos/pvolok/aphrodite/releases{/id}","deployments_url":"https://api.github.com/repos/pvolok/aphrodite/deployments","created_at":"2016-06-01T07:51:36Z","updated_at":"2016-06-01T07:51:37Z","pushed_at":"2016-06-06T20:38:34Z","git_url":"git://github.com/pvolok/aphrodite.git","ssh_url":"git@github.com:pvolok/aphrodite.git","clone_url":"https://github.com/pvolok/aphrodite.git","svn_url":"https://github.com/pvolok/aphrodite","homepage":null,"size":149,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"Khan:master","ref":"master","sha":"6b0560fa6d22432ccee295cee8f9a71b92766a21","user":{"login":"Khan","id":15455,"avatar_url":"https://avatars.githubusercontent.com/u/15455?v=3","gravatar_id":"","url":"https://api.github.com/users/Khan","html_url":"https://github.com/Khan","followers_url":"https://api.github.com/users/Khan/followers","following_url":"https://api.github.com/users/Khan/following{/other_user}","gists_url":"https://api.github.com/users/Khan/gists{/gist_id}","starred_url":"https://api.github.com/users/Khan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Khan/subscriptions","organizations_url":"https://api.github.com/users/Khan/orgs","repos_url":"https://api.github.com/users/Khan/repos","events_url":"https://api.github.com/users/Khan/events{/privacy}","received_events_url":"https://api.github.com/users/Khan/received_events","type":"Organization","site_admin":false},"repo":{"id":43790903,"name":"aphrodite","full_name":"Khan/aphrodite","owner":{"login":"Khan","id":15455,"avatar_url":"https://avatars.githubusercontent.com/u/15455?v=3","gravatar_id":"","url":"https://api.github.com/users/Khan","html_url":"https://github.com/Khan","followers_url":"https://api.github.com/users/Khan/followers","following_url":"https://api.github.com/users/Khan/following{/other_user}","gists_url":"https://api.github.com/users/Khan/gists{/gist_id}","starred_url":"https://api.github.com/users/Khan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Khan/subscriptions","organizations_url":"https://api.github.com/users/Khan/orgs","repos_url":"https://api.github.com/users/Khan/repos","events_url":"https://api.github.com/users/Khan/events{/privacy}","received_events_url":"https://api.github.com/users/Khan/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Khan/aphrodite","description":"It's inline styles, but they work!","fork":false,"url":"https://api.github.com/repos/Khan/aphrodite","forks_url":"https://api.github.com/repos/Khan/aphrodite/forks","keys_url":"https://api.github.com/repos/Khan/aphrodite/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Khan/aphrodite/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Khan/aphrodite/teams","hooks_url":"https://api.github.com/repos/Khan/aphrodite/hooks","issue_events_url":"https://api.github.com/repos/Khan/aphrodite/issues/events{/number}","events_url":"https://api.github.com/repos/Khan/aphrodite/events","assignees_url":"https://api.github.com/repos/Khan/aphrodite/assignees{/user}","branches_url":"https://api.github.com/repos/Khan/aphrodite/branches{/branch}","tags_url":"https://api.github.com/repos/Khan/aphrodite/tags","blobs_url":"https://api.github.com/repos/Khan/aphrodite/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Khan/aphrodite/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Khan/aphrodite/git/refs{/sha}","trees_url":"https://api.github.com/repos/Khan/aphrodite/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Khan/aphrodite/statuses/{sha}","languages_url":"https://api.github.com/repos/Khan/aphrodite/languages","stargazers_url":"https://api.github.com/repos/Khan/aphrodite/stargazers","contributors_url":"https://api.github.com/repos/Khan/aphrodite/contributors","subscribers_url":"https://api.github.com/repos/Khan/aphrodite/subscribers","subscription_url":"https://api.github.com/repos/Khan/aphrodite/subscription","commits_url":"https://api.github.com/repos/Khan/aphrodite/commits{/sha}","git_commits_url":"https://api.github.com/repos/Khan/aphrodite/git/commits{/sha}","comments_url":"https://api.github.com/repos/Khan/aphrodite/comments{/number}","issue_comment_url":"https://api.github.com/repos/Khan/aphrodite/issues/comments{/number}","contents_url":"https://api.github.com/repos/Khan/aphrodite/contents/{+path}","compare_url":"https://api.github.com/repos/Khan/aphrodite/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Khan/aphrodite/merges","archive_url":"https://api.github.com/repos/Khan/aphrodite/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Khan/aphrodite/downloads","issues_url":"https://api.github.com/repos/Khan/aphrodite/issues{/number}","pulls_url":"https://api.github.com/repos/Khan/aphrodite/pulls{/number}","milestones_url":"https://api.github.com/repos/Khan/aphrodite/milestones{/number}","notifications_url":"https://api.github.com/repos/Khan/aphrodite/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Khan/aphrodite/labels{/name}","releases_url":"https://api.github.com/repos/Khan/aphrodite/releases{/id}","deployments_url":"https://api.github.com/repos/Khan/aphrodite/deployments","created_at":"2015-10-07T02:31:35Z","updated_at":"2016-06-06T20:49:33Z","pushed_at":"2016-06-06T20:38:34Z","git_url":"git://github.com/Khan/aphrodite.git","ssh_url":"git@github.com:Khan/aphrodite.git","clone_url":"https://github.com/Khan/aphrodite.git","svn_url":"https://github.com/Khan/aphrodite","homepage":null,"size":227,"stargazers_count":908,"watchers_count":908,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":35,"mirror_url":null,"open_issues_count":20,"forks":35,"open_issues":20,"watchers":908,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Khan/aphrodite/pulls/83"},"html":{"href":"https://github.com/Khan/aphrodite/pull/83"},"issue":{"href":"https://api.github.com/repos/Khan/aphrodite/issues/83"},"comments":{"href":"https://api.github.com/repos/Khan/aphrodite/issues/83/comments"},"review_comments":{"href":"https://api.github.com/repos/Khan/aphrodite/pulls/83/comments"},"review_comment":{"href":"https://api.github.com/repos/Khan/aphrodite/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Khan/aphrodite/pulls/83/commits"},"statuses":{"href":"https://api.github.com/repos/Khan/aphrodite/statuses/af72eae994f55fb1afaa56ddcaf6a70ef5a8043c"}}}}
{"actor":{"display_login":"kentcdodds"}}