Skip to content

Commit

Permalink
fix($plugin-pwa): service worker doesn't work under sub directory (close
Browse files Browse the repository at this point in the history
  • Loading branch information
ulivz committed Feb 18, 2019
1 parent 898033c commit 0d56a99
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/@vuepress/plugin-pwa/lib/enhanceAppFile.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export default ({ router, isServer }) => {
&& !isServer
&& SW_ENABLED) {
register(`${SW_BASE_URL}service-worker.js`, {
registrationOptions: { scope: `./${SW_BASE_URL}` },
registrationOptions: {},
ready () {
console.log('[vuepress:sw] Service worker is active.')
event.$emit('sw-ready')
Expand Down

0 comments on commit 0d56a99

Please sign in to comment.