{"action":"created","comment":{"url":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/comments/29703725","id":29703725,"diff_hunk":"@@ -0,0 +1,69 @@\n+(() => {\n+'use strict';\n+\n+/**\n+ * Module dependencies\n+ */\n+var perf = window.performance;\n+\n+var initialized = false;\n+var count = 0;\n+var worker;\n+\n+function render() {\n+  var element = document.getElementsByClassName('count')[0];\n+  element.innerHTML = count;\n+}\n+\n+function main() {\n+  // Since our entire UI is in index.html, we can emit Chrome Visible.\n+  perf.mark('moz-chrome-dom-loaded');\n+\n+  console.log('Binding event handlers...');\n+  var plus = document.getElementsByClassName('plus')[0];\n+  plus.addEventListener('click', event => {\n+    if (!initialized) {\n+      return;\n+    }\n+\n+    count += 1;\n+    render();\n+    worker.postMessage({ method: 'setCount', params: [count] });\n+  });\n+\n+  var minus = document.getElementsByClassName('minus')[0];\n+  minus.addEventListener('click', event => {\n+    if (!initialized) {\n+      return;\n+    }\n+\n+    count -= 1;\n+    render();\n+    worker.postMessage({ method: 'setCount', params: [count] });\n+  });\n+\n+  render();\n+\n+  // Now that people can tick the counter up and down,\n+  // we can mark the Chrome Interactive.\n+  perf.mark('moz-chrome-interactive');\n+\n+  // Start our worker and ask for the current counter count.\n+  console.log('Staring worker...');\n+  worker = new Worker('/js/worker.js');\n+  worker.postMessage({ method: 'getCount' });\n+  worker.onmessage = event => {\n+    // We got the current counter value from the worker.\n+    count = event.data;\n+    initialized = true;\n+    render();\n+    // Now the app is 100% ready to go.\n+    perf.mark('moz-app-visually-complete');\n+    perf.mark('moz-content-interactive');","path":"dev_apps/test-startup-limit/js/app.js","position":62,"original_position":62,"commit_id":"a36a7aa3dff7bd31ab98cbee5ae2b8dc066dee76","original_commit_id":"a36a7aa3dff7bd31ab98cbee5ae2b8dc066dee76","user":{"login":"eliperelman","id":285899,"avatar_url":"https://avatars.githubusercontent.com/u/285899?v=3","gravatar_id":"","url":"https://api.github.com/users/eliperelman","html_url":"https://github.com/eliperelman","followers_url":"https://api.github.com/users/eliperelman/followers","following_url":"https://api.github.com/users/eliperelman/following{/other_user}","gists_url":"https://api.github.com/users/eliperelman/gists{/gist_id}","starred_url":"https://api.github.com/users/eliperelman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eliperelman/subscriptions","organizations_url":"https://api.github.com/users/eliperelman/orgs","repos_url":"https://api.github.com/users/eliperelman/repos","events_url":"https://api.github.com/users/eliperelman/events{/privacy}","received_events_url":"https://api.github.com/users/eliperelman/received_events","type":"User","site_admin":false},"body":"Change to `contentInteractive`.","created_at":"2015-05-05T19:28:26Z","updated_at":"2015-05-05T19:28:26Z","html_url":"https://github.com/mozilla-b2g/gaia/pull/29897#discussion_r29703725","pull_request_url":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/29897","_links":{"self":{"href":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/comments/29703725"},"html":{"href":"https://github.com/mozilla-b2g/gaia/pull/29897#discussion_r29703725"},"pull_request":{"href":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/29897"}}},"pull_request":{"url":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/29897","id":34756887,"html_url":"https://github.com/mozilla-b2g/gaia/pull/29897","diff_url":"https://github.com/mozilla-b2g/gaia/pull/29897.diff","patch_url":"https://github.com/mozilla-b2g/gaia/pull/29897.patch","issue_url":"https://api.github.com/repos/mozilla-b2g/gaia/issues/29897","number":29897,"state":"open","locked":false,"title":"Bug 1161633 - Create bare bones app that represents theoretical lows for app startup perf r=Eli","user":{"login":"gaye","id":535859,"avatar_url":"https://avatars.githubusercontent.com/u/535859?v=3","gravatar_id":"","url":"https://api.github.com/users/gaye","html_url":"https://github.com/gaye","followers_url":"https://api.github.com/users/gaye/followers","following_url":"https://api.github.com/users/gaye/following{/other_user}","gists_url":"https://api.github.com/users/gaye/gists{/gist_id}","starred_url":"https://api.github.com/users/gaye/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gaye/subscriptions","organizations_url":"https://api.github.com/users/gaye/orgs","repos_url":"https://api.github.com/users/gaye/repos","events_url":"https://api.github.com/users/gaye/events{/privacy}","received_events_url":"https://api.github.com/users/gaye/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-05-05T19:11:28Z","updated_at":"2015-05-05T19:28:26Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7125c635dbddaef0e52a4a74cc195499c6fb8ff8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/29897/commits","review_comments_url":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/29897/comments","review_comment_url":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mozilla-b2g/gaia/issues/29897/comments","statuses_url":"https://api.github.com/repos/mozilla-b2g/gaia/statuses/a36a7aa3dff7bd31ab98cbee5ae2b8dc066dee76","head":{"label":"gaye:bug-1161633-test-startup-limit","ref":"bug-1161633-test-startup-limit","sha":"a36a7aa3dff7bd31ab98cbee5ae2b8dc066dee76","user":{"login":"gaye","id":535859,"avatar_url":"https://avatars.githubusercontent.com/u/535859?v=3","gravatar_id":"","url":"https://api.github.com/users/gaye","html_url":"https://github.com/gaye","followers_url":"https://api.github.com/users/gaye/followers","following_url":"https://api.github.com/users/gaye/following{/other_user}","gists_url":"https://api.github.com/users/gaye/gists{/gist_id}","starred_url":"https://api.github.com/users/gaye/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gaye/subscriptions","organizations_url":"https://api.github.com/users/gaye/orgs","repos_url":"https://api.github.com/users/gaye/repos","events_url":"https://api.github.com/users/gaye/events{/privacy}","received_events_url":"https://api.github.com/users/gaye/received_events","type":"User","site_admin":false},"repo":{"id":9064811,"name":"gaia","full_name":"gaye/gaia","owner":{"login":"gaye","id":535859,"avatar_url":"https://avatars.githubusercontent.com/u/535859?v=3","gravatar_id":"","url":"https://api.github.com/users/gaye","html_url":"https://github.com/gaye","followers_url":"https://api.github.com/users/gaye/followers","following_url":"https://api.github.com/users/gaye/following{/other_user}","gists_url":"https://api.github.com/users/gaye/gists{/gist_id}","starred_url":"https://api.github.com/users/gaye/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gaye/subscriptions","organizations_url":"https://api.github.com/users/gaye/orgs","repos_url":"https://api.github.com/users/gaye/repos","events_url":"https://api.github.com/users/gaye/events{/privacy}","received_events_url":"https://api.github.com/users/gaye/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/gaye/gaia","description":"Gaia is a HTML5-based Phone UI for the Boot 2 Gecko Project. NOTE: For details of what branches are used for what releases, see https://wiki.mozilla.org/Release_Management/B2G_Landing","fork":true,"url":"https://api.github.com/repos/gaye/gaia","forks_url":"https://api.github.com/repos/gaye/gaia/forks","keys_url":"https://api.github.com/repos/gaye/gaia/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gaye/gaia/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gaye/gaia/teams","hooks_url":"https://api.github.com/repos/gaye/gaia/hooks","issue_events_url":"https://api.github.com/repos/gaye/gaia/issues/events{/number}","events_url":"https://api.github.com/repos/gaye/gaia/events","assignees_url":"https://api.github.com/repos/gaye/gaia/assignees{/user}","branches_url":"https://api.github.com/repos/gaye/gaia/branches{/branch}","tags_url":"https://api.github.com/repos/gaye/gaia/tags","blobs_url":"https://api.github.com/repos/gaye/gaia/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gaye/gaia/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gaye/gaia/git/refs{/sha}","trees_url":"https://api.github.com/repos/gaye/gaia/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gaye/gaia/statuses/{sha}","languages_url":"https://api.github.com/repos/gaye/gaia/languages","stargazers_url":"https://api.github.com/repos/gaye/gaia/stargazers","contributors_url":"https://api.github.com/repos/gaye/gaia/contributors","subscribers_url":"https://api.github.com/repos/gaye/gaia/subscribers","subscription_url":"https://api.github.com/repos/gaye/gaia/subscription","commits_url":"https://api.github.com/repos/gaye/gaia/commits{/sha}","git_commits_url":"https://api.github.com/repos/gaye/gaia/git/commits{/sha}","comments_url":"https://api.github.com/repos/gaye/gaia/comments{/number}","issue_comment_url":"https://api.github.com/repos/gaye/gaia/issues/comments{/number}","contents_url":"https://api.github.com/repos/gaye/gaia/contents/{+path}","compare_url":"https://api.github.com/repos/gaye/gaia/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gaye/gaia/merges","archive_url":"https://api.github.com/repos/gaye/gaia/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gaye/gaia/downloads","issues_url":"https://api.github.com/repos/gaye/gaia/issues{/number}","pulls_url":"https://api.github.com/repos/gaye/gaia/pulls{/number}","milestones_url":"https://api.github.com/repos/gaye/gaia/milestones{/number}","notifications_url":"https://api.github.com/repos/gaye/gaia/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gaye/gaia/labels{/name}","releases_url":"https://api.github.com/repos/gaye/gaia/releases{/id}","created_at":"2013-03-27T22:12:16Z","updated_at":"2015-01-22T18:41:20Z","pushed_at":"2015-05-05T19:26:32Z","git_url":"git://github.com/gaye/gaia.git","ssh_url":"git@github.com:gaye/gaia.git","clone_url":"https://github.com/gaye/gaia.git","svn_url":"https://github.com/gaye/gaia","homepage":"https://wiki.mozilla.org/B2G","size":883052,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"mozilla-b2g:master","ref":"master","sha":"a07cd0da50afdc8fcc6b8a3a765da2507bce5c31","user":{"login":"mozilla-b2g","id":1261292,"avatar_url":"https://avatars.githubusercontent.com/u/1261292?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla-b2g","html_url":"https://github.com/mozilla-b2g","followers_url":"https://api.github.com/users/mozilla-b2g/followers","following_url":"https://api.github.com/users/mozilla-b2g/following{/other_user}","gists_url":"https://api.github.com/users/mozilla-b2g/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla-b2g/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla-b2g/subscriptions","organizations_url":"https://api.github.com/users/mozilla-b2g/orgs","repos_url":"https://api.github.com/users/mozilla-b2g/repos","events_url":"https://api.github.com/users/mozilla-b2g/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla-b2g/received_events","type":"Organization","site_admin":false},"repo":{"id":2317369,"name":"gaia","full_name":"mozilla-b2g/gaia","owner":{"login":"mozilla-b2g","id":1261292,"avatar_url":"https://avatars.githubusercontent.com/u/1261292?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla-b2g","html_url":"https://github.com/mozilla-b2g","followers_url":"https://api.github.com/users/mozilla-b2g/followers","following_url":"https://api.github.com/users/mozilla-b2g/following{/other_user}","gists_url":"https://api.github.com/users/mozilla-b2g/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla-b2g/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla-b2g/subscriptions","organizations_url":"https://api.github.com/users/mozilla-b2g/orgs","repos_url":"https://api.github.com/users/mozilla-b2g/repos","events_url":"https://api.github.com/users/mozilla-b2g/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla-b2g/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mozilla-b2g/gaia","description":"Gaia is a HTML5-based Phone UI for the Boot 2 Gecko Project. NOTE: For details of what branches are used for what releases, see","fork":false,"url":"https://api.github.com/repos/mozilla-b2g/gaia","forks_url":"https://api.github.com/repos/mozilla-b2g/gaia/forks","keys_url":"https://api.github.com/repos/mozilla-b2g/gaia/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mozilla-b2g/gaia/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mozilla-b2g/gaia/teams","hooks_url":"https://api.github.com/repos/mozilla-b2g/gaia/hooks","issue_events_url":"https://api.github.com/repos/mozilla-b2g/gaia/issues/events{/number}","events_url":"https://api.github.com/repos/mozilla-b2g/gaia/events","assignees_url":"https://api.github.com/repos/mozilla-b2g/gaia/assignees{/user}","branches_url":"https://api.github.com/repos/mozilla-b2g/gaia/branches{/branch}","tags_url":"https://api.github.com/repos/mozilla-b2g/gaia/tags","blobs_url":"https://api.github.com/repos/mozilla-b2g/gaia/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mozilla-b2g/gaia/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mozilla-b2g/gaia/git/refs{/sha}","trees_url":"https://api.github.com/repos/mozilla-b2g/gaia/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mozilla-b2g/gaia/statuses/{sha}","languages_url":"https://api.github.com/repos/mozilla-b2g/gaia/languages","stargazers_url":"https://api.github.com/repos/mozilla-b2g/gaia/stargazers","contributors_url":"https://api.github.com/repos/mozilla-b2g/gaia/contributors","subscribers_url":"https://api.github.com/repos/mozilla-b2g/gaia/subscribers","subscription_url":"https://api.github.com/repos/mozilla-b2g/gaia/subscription","commits_url":"https://api.github.com/repos/mozilla-b2g/gaia/commits{/sha}","git_commits_url":"https://api.github.com/repos/mozilla-b2g/gaia/git/commits{/sha}","comments_url":"https://api.github.com/repos/mozilla-b2g/gaia/comments{/number}","issue_comment_url":"https://api.github.com/repos/mozilla-b2g/gaia/issues/comments{/number}","contents_url":"https://api.github.com/repos/mozilla-b2g/gaia/contents/{+path}","compare_url":"https://api.github.com/repos/mozilla-b2g/gaia/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mozilla-b2g/gaia/merges","archive_url":"https://api.github.com/repos/mozilla-b2g/gaia/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mozilla-b2g/gaia/downloads","issues_url":"https://api.github.com/repos/mozilla-b2g/gaia/issues{/number}","pulls_url":"https://api.github.com/repos/mozilla-b2g/gaia/pulls{/number}","milestones_url":"https://api.github.com/repos/mozilla-b2g/gaia/milestones{/number}","notifications_url":"https://api.github.com/repos/mozilla-b2g/gaia/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mozilla-b2g/gaia/labels{/name}","releases_url":"https://api.github.com/repos/mozilla-b2g/gaia/releases{/id}","created_at":"2011-09-03T01:38:46Z","updated_at":"2015-05-05T19:17:29Z","pushed_at":"2015-05-05T19:26:36Z","git_url":"git://github.com/mozilla-b2g/gaia.git","ssh_url":"git@github.com:mozilla-b2g/gaia.git","clone_url":"https://github.com/mozilla-b2g/gaia.git","svn_url":"https://github.com/mozilla-b2g/gaia","homepage":"https://wiki.mozilla.org/B2G","size":1538826,"stargazers_count":1916,"watchers_count":1916,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2299,"mirror_url":null,"open_issues_count":985,"forks":2299,"open_issues":985,"watchers":1916,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/29897"},"html":{"href":"https://github.com/mozilla-b2g/gaia/pull/29897"},"issue":{"href":"https://api.github.com/repos/mozilla-b2g/gaia/issues/29897"},"comments":{"href":"https://api.github.com/repos/mozilla-b2g/gaia/issues/29897/comments"},"review_comments":{"href":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/29897/comments"},"review_comment":{"href":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mozilla-b2g/gaia/pulls/29897/commits"},"statuses":{"href":"https://api.github.com/repos/mozilla-b2g/gaia/statuses/a36a7aa3dff7bd31ab98cbee5ae2b8dc066dee76"}}}}