{"action":"opened","number":525,"pull_request":{"url":"https://api.github.com/repos/bemusic/bemuse/pulls/525","id":240639216,"node_id":"MDExOlB1bGxSZXF1ZXN0MjQwNjM5MjE2","html_url":"https://github.com/bemusic/bemuse/pull/525","diff_url":"https://github.com/bemusic/bemuse/pull/525.diff","patch_url":"https://github.com/bemusic/bemuse/pull/525.patch","issue_url":"https://api.github.com/repos/bemusic/bemuse/issues/525","number":525,"state":"open","locked":false,"title":":building_construction: Remove service-worker hack","user":{"login":"resir014","id":5663877,"node_id":"MDQ6VXNlcjU2NjM4Nzc=","avatar_url":"https://avatars0.githubusercontent.com/u/5663877?v=4","gravatar_id":"","url":"https://api.github.com/users/resir014","html_url":"https://github.com/resir014","followers_url":"https://api.github.com/users/resir014/followers","following_url":"https://api.github.com/users/resir014/following{/other_user}","gists_url":"https://api.github.com/users/resir014/gists{/gist_id}","starred_url":"https://api.github.com/users/resir014/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/resir014/subscriptions","organizations_url":"https://api.github.com/users/resir014/orgs","repos_url":"https://api.github.com/users/resir014/repos","events_url":"https://api.github.com/users/resir014/events{/privacy}","received_events_url":"https://api.github.com/users/resir014/received_events","type":"User","site_admin":false},"body":"## Motivation\r\n\r\nWe used some kinda of hack to get the service worker URL to register it, but we can actually do it with `serviceworker-webpack-plugin` to be able to load up our custom service worker without having to rewrite everything in Workbox.\r\n\r\nSo we can keep our existing service worker, but to include it, we can simply do this:\r\n\r\n```diff\r\n- import workerPath from 'bemuse/hacks/service-worker-url/index.loader.js!serviceworker-loader!./service-worker.js'\r\n+ import serviceWorkerRuntime from 'serviceworker-webpack-plugin/lib/runtime'\r\n```\r\n\r\n## Things to note\r\n\r\n- Since we're rebuilding our service worker, need to figure out a way to 'safely' unregister the old service worker before installing the new one.\r\n- I had to update the webpack config so that the `publicPath` is set at the `/` directory. This means I needed to rewrite some configs in webpack to reflect that change (specifically with file output.).\r\n- No TS typings included for the `serviceworker-webpack-plugin` runtime, so I had to include the typings myself. ","created_at":"2018-12-22T15:02:51Z","updated_at":"2018-12-22T15:02:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/bemusic/bemuse/pulls/525/commits","review_comments_url":"https://api.github.com/repos/bemusic/bemuse/pulls/525/comments","review_comment_url":"https://api.github.com/repos/bemusic/bemuse/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bemusic/bemuse/issues/525/comments","statuses_url":"https://api.github.com/repos/bemusic/bemuse/statuses/56bc60c779000467408d50f0c237488f1557b51c","head":{"label":"bemusic:use-service-worker-plugin","ref":"use-service-worker-plugin","sha":"56bc60c779000467408d50f0c237488f1557b51c","user":{"login":"bemusic","id":10154884,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMTU0ODg0","avatar_url":"https://avatars2.githubusercontent.com/u/10154884?v=4","gravatar_id":"","url":"https://api.github.com/users/bemusic","html_url":"https://github.com/bemusic","followers_url":"https://api.github.com/users/bemusic/followers","following_url":"https://api.github.com/users/bemusic/following{/other_user}","gists_url":"https://api.github.com/users/bemusic/gists{/gist_id}","starred_url":"https://api.github.com/users/bemusic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bemusic/subscriptions","organizations_url":"https://api.github.com/users/bemusic/orgs","repos_url":"https://api.github.com/users/bemusic/repos","events_url":"https://api.github.com/users/bemusic/events{/privacy}","received_events_url":"https://api.github.com/users/bemusic/received_events","type":"Organization","site_admin":false},"repo":{"id":27105154,"node_id":"MDEwOlJlcG9zaXRvcnkyNzEwNTE1NA==","name":"bemuse","full_name":"bemusic/bemuse","private":false,"owner":{"login":"bemusic","id":10154884,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMTU0ODg0","avatar_url":"https://avatars2.githubusercontent.com/u/10154884?v=4","gravatar_id":"","url":"https://api.github.com/users/bemusic","html_url":"https://github.com/bemusic","followers_url":"https://api.github.com/users/bemusic/followers","following_url":"https://api.github.com/users/bemusic/following{/other_user}","gists_url":"https://api.github.com/users/bemusic/gists{/gist_id}","starred_url":"https://api.github.com/users/bemusic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bemusic/subscriptions","organizations_url":"https://api.github.com/users/bemusic/orgs","repos_url":"https://api.github.com/users/bemusic/repos","events_url":"https://api.github.com/users/bemusic/events{/privacy}","received_events_url":"https://api.github.com/users/bemusic/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/bemusic/bemuse","description":"⬤▗▚▚▚ Web-based online rhythm action game. Based on HTML5 technologies, React, Redux and Pixi.js.","fork":false,"url":"https://api.github.com/repos/bemusic/bemuse","forks_url":"https://api.github.com/repos/bemusic/bemuse/forks","keys_url":"https://api.github.com/repos/bemusic/bemuse/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bemusic/bemuse/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bemusic/bemuse/teams","hooks_url":"https://api.github.com/repos/bemusic/bemuse/hooks","issue_events_url":"https://api.github.com/repos/bemusic/bemuse/issues/events{/number}","events_url":"https://api.github.com/repos/bemusic/bemuse/events","assignees_url":"https://api.github.com/repos/bemusic/bemuse/assignees{/user}","branches_url":"https://api.github.com/repos/bemusic/bemuse/branches{/branch}","tags_url":"https://api.github.com/repos/bemusic/bemuse/tags","blobs_url":"https://api.github.com/repos/bemusic/bemuse/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bemusic/bemuse/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bemusic/bemuse/git/refs{/sha}","trees_url":"https://api.github.com/repos/bemusic/bemuse/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bemusic/bemuse/statuses/{sha}","languages_url":"https://api.github.com/repos/bemusic/bemuse/languages","stargazers_url":"https://api.github.com/repos/bemusic/bemuse/stargazers","contributors_url":"https://api.github.com/repos/bemusic/bemuse/contributors","subscribers_url":"https://api.github.com/repos/bemusic/bemuse/subscribers","subscription_url":"https://api.github.com/repos/bemusic/bemuse/subscription","commits_url":"https://api.github.com/repos/bemusic/bemuse/commits{/sha}","git_commits_url":"https://api.github.com/repos/bemusic/bemuse/git/commits{/sha}","comments_url":"https://api.github.com/repos/bemusic/bemuse/comments{/number}","issue_comment_url":"https://api.github.com/repos/bemusic/bemuse/issues/comments{/number}","contents_url":"https://api.github.com/repos/bemusic/bemuse/contents/{+path}","compare_url":"https://api.github.com/repos/bemusic/bemuse/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bemusic/bemuse/merges","archive_url":"https://api.github.com/repos/bemusic/bemuse/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bemusic/bemuse/downloads","issues_url":"https://api.github.com/repos/bemusic/bemuse/issues{/number}","pulls_url":"https://api.github.com/repos/bemusic/bemuse/pulls{/number}","milestones_url":"https://api.github.com/repos/bemusic/bemuse/milestones{/number}","notifications_url":"https://api.github.com/repos/bemusic/bemuse/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bemusic/bemuse/labels{/name}","releases_url":"https://api.github.com/repos/bemusic/bemuse/releases{/id}","deployments_url":"https://api.github.com/repos/bemusic/bemuse/deployments","created_at":"2014-11-25T02:20:29Z","updated_at":"2018-12-22T00:41:49Z","pushed_at":"2018-12-22T14:55:31Z","git_url":"git://github.com/bemusic/bemuse.git","ssh_url":"git@github.com:bemusic/bemuse.git","clone_url":"https://github.com/bemusic/bemuse.git","svn_url":"https://github.com/bemusic/bemuse","homepage":"https://bemuse.ninja/","size":25767,"stargazers_count":512,"watchers_count":512,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":66,"mirror_url":null,"archived":false,"open_issues_count":28,"license":{"key":"agpl-3.0","name":"GNU Affero General Public License v3.0","spdx_id":"AGPL-3.0","url":"https://api.github.com/licenses/agpl-3.0","node_id":"MDc6TGljZW5zZTE="},"forks":66,"open_issues":28,"watchers":512,"default_branch":"master"}},"base":{"label":"bemusic:master","ref":"master","sha":"71b9091052163346e103c66a80ca0e91b1f6f14d","user":{"login":"bemusic","id":10154884,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMTU0ODg0","avatar_url":"https://avatars2.githubusercontent.com/u/10154884?v=4","gravatar_id":"","url":"https://api.github.com/users/bemusic","html_url":"https://github.com/bemusic","followers_url":"https://api.github.com/users/bemusic/followers","following_url":"https://api.github.com/users/bemusic/following{/other_user}","gists_url":"https://api.github.com/users/bemusic/gists{/gist_id}","starred_url":"https://api.github.com/users/bemusic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bemusic/subscriptions","organizations_url":"https://api.github.com/users/bemusic/orgs","repos_url":"https://api.github.com/users/bemusic/repos","events_url":"https://api.github.com/users/bemusic/events{/privacy}","received_events_url":"https://api.github.com/users/bemusic/received_events","type":"Organization","site_admin":false},"repo":{"id":27105154,"node_id":"MDEwOlJlcG9zaXRvcnkyNzEwNTE1NA==","name":"bemuse","full_name":"bemusic/bemuse","private":false,"owner":{"login":"bemusic","id":10154884,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMTU0ODg0","avatar_url":"https://avatars2.githubusercontent.com/u/10154884?v=4","gravatar_id":"","url":"https://api.github.com/users/bemusic","html_url":"https://github.com/bemusic","followers_url":"https://api.github.com/users/bemusic/followers","following_url":"https://api.github.com/users/bemusic/following{/other_user}","gists_url":"https://api.github.com/users/bemusic/gists{/gist_id}","starred_url":"https://api.github.com/users/bemusic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bemusic/subscriptions","organizations_url":"https://api.github.com/users/bemusic/orgs","repos_url":"https://api.github.com/users/bemusic/repos","events_url":"https://api.github.com/users/bemusic/events{/privacy}","received_events_url":"https://api.github.com/users/bemusic/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/bemusic/bemuse","description":"⬤▗▚▚▚ Web-based online rhythm action game. Based on HTML5 technologies, React, Redux and Pixi.js.","fork":false,"url":"https://api.github.com/repos/bemusic/bemuse","forks_url":"https://api.github.com/repos/bemusic/bemuse/forks","keys_url":"https://api.github.com/repos/bemusic/bemuse/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bemusic/bemuse/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bemusic/bemuse/teams","hooks_url":"https://api.github.com/repos/bemusic/bemuse/hooks","issue_events_url":"https://api.github.com/repos/bemusic/bemuse/issues/events{/number}","events_url":"https://api.github.com/repos/bemusic/bemuse/events","assignees_url":"https://api.github.com/repos/bemusic/bemuse/assignees{/user}","branches_url":"https://api.github.com/repos/bemusic/bemuse/branches{/branch}","tags_url":"https://api.github.com/repos/bemusic/bemuse/tags","blobs_url":"https://api.github.com/repos/bemusic/bemuse/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bemusic/bemuse/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bemusic/bemuse/git/refs{/sha}","trees_url":"https://api.github.com/repos/bemusic/bemuse/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bemusic/bemuse/statuses/{sha}","languages_url":"https://api.github.com/repos/bemusic/bemuse/languages","stargazers_url":"https://api.github.com/repos/bemusic/bemuse/stargazers","contributors_url":"https://api.github.com/repos/bemusic/bemuse/contributors","subscribers_url":"https://api.github.com/repos/bemusic/bemuse/subscribers","subscription_url":"https://api.github.com/repos/bemusic/bemuse/subscription","commits_url":"https://api.github.com/repos/bemusic/bemuse/commits{/sha}","git_commits_url":"https://api.github.com/repos/bemusic/bemuse/git/commits{/sha}","comments_url":"https://api.github.com/repos/bemusic/bemuse/comments{/number}","issue_comment_url":"https://api.github.com/repos/bemusic/bemuse/issues/comments{/number}","contents_url":"https://api.github.com/repos/bemusic/bemuse/contents/{+path}","compare_url":"https://api.github.com/repos/bemusic/bemuse/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bemusic/bemuse/merges","archive_url":"https://api.github.com/repos/bemusic/bemuse/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bemusic/bemuse/downloads","issues_url":"https://api.github.com/repos/bemusic/bemuse/issues{/number}","pulls_url":"https://api.github.com/repos/bemusic/bemuse/pulls{/number}","milestones_url":"https://api.github.com/repos/bemusic/bemuse/milestones{/number}","notifications_url":"https://api.github.com/repos/bemusic/bemuse/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bemusic/bemuse/labels{/name}","releases_url":"https://api.github.com/repos/bemusic/bemuse/releases{/id}","deployments_url":"https://api.github.com/repos/bemusic/bemuse/deployments","created_at":"2014-11-25T02:20:29Z","updated_at":"2018-12-22T00:41:49Z","pushed_at":"2018-12-22T14:55:31Z","git_url":"git://github.com/bemusic/bemuse.git","ssh_url":"git@github.com:bemusic/bemuse.git","clone_url":"https://github.com/bemusic/bemuse.git","svn_url":"https://github.com/bemusic/bemuse","homepage":"https://bemuse.ninja/","size":25767,"stargazers_count":512,"watchers_count":512,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":66,"mirror_url":null,"archived":false,"open_issues_count":28,"license":{"key":"agpl-3.0","name":"GNU Affero General Public License v3.0","spdx_id":"AGPL-3.0","url":"https://api.github.com/licenses/agpl-3.0","node_id":"MDc6TGljZW5zZTE="},"forks":66,"open_issues":28,"watchers":512,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bemusic/bemuse/pulls/525"},"html":{"href":"https://github.com/bemusic/bemuse/pull/525"},"issue":{"href":"https://api.github.com/repos/bemusic/bemuse/issues/525"},"comments":{"href":"https://api.github.com/repos/bemusic/bemuse/issues/525/comments"},"review_comments":{"href":"https://api.github.com/repos/bemusic/bemuse/pulls/525/comments"},"review_comment":{"href":"https://api.github.com/repos/bemusic/bemuse/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bemusic/bemuse/pulls/525/commits"},"statuses":{"href":"https://api.github.com/repos/bemusic/bemuse/statuses/56bc60c779000467408d50f0c237488f1557b51c"}},"author_association":"MEMBER","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":false,"commits":1,"additions":38,"deletions":21,"changed_files":7}}
{"actor":{"display_login":"resir014"}}