Browse Source

fix #4356 : place sw.js to assets/sw.js (#4357)

Satoshi KOJIMA 2 years ago
parent
commit
e54cc15cbd
3 changed files with 2 additions and 2 deletions
  1. 0 1
      .gitignore
  2. 1 1
      config/webpack/production.js
  3. 1 0
      public/sw.js

+ 0 - 1
.gitignore View File

@@ -21,7 +21,6 @@ public/system
21 21
 public/assets
22 22
 public/packs
23 23
 public/packs-test
24
-public/sw.js
25 24
 .env
26 25
 .env.production
27 26
 node_modules/

+ 1 - 1
config/webpack/production.js View File

@@ -48,7 +48,7 @@ module.exports = merge(sharedConfig, {
48 48
       ServiceWorker: {
49 49
         entry: path.join(__dirname, '../../app/javascript/mastodon/service_worker/entry.js'),
50 50
         cacheName: 'mastodon',
51
-        output: '../sw.js',
51
+        output: '../assets/sw.js',
52 52
         publicPath: '/sw.js',
53 53
         minify: true,
54 54
       },

+ 1 - 0
public/sw.js View File

@@ -0,0 +1 @@
1
+assets/sw.js