@docusaurus/plugin-pwa 0.0.0-6094 → 0.0.0-6095

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/index.js CHANGED
@@ -66,11 +66,7 @@ function pluginPWA(context, options) {
66
66
  configureWebpack(config, isServer, { currentBundler }) {
67
67
  return {
68
68
  plugins: [
69
- new currentBundler.instance.EnvironmentPlugin(
70
- // See https://github.com/facebook/docusaurus/pull/10455#issuecomment-2317593528
71
- // See https://github.com/webpack/webpack/commit/adf2a6b7c6077fd806ea0e378c1450cccecc9ed0#r145989788
72
- // @ts-expect-error: bad Webpack type?
73
- {
69
+ new currentBundler.instance.EnvironmentPlugin({
74
70
  PWA_DEBUG: debug,
75
71
  PWA_SERVICE_WORKER_URL: path_1.default.posix.resolve(`${config.output?.publicPath || '/'}`, 'sw.js'),
76
72
  PWA_OFFLINE_MODE_ACTIVATION_STRATEGIES: offlineModeActivationStrategies,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@docusaurus/plugin-pwa",
3
- "version": "0.0.0-6094",
3
+ "version": "0.0.0-6095",
4
4
  "description": "Docusaurus Plugin to add PWA support.",
5
5
  "main": "lib/index.js",
6
6
  "types": "src/plugin-pwa.d.ts",
@@ -22,26 +22,26 @@
22
22
  "dependencies": {
23
23
  "@babel/core": "^7.23.3",
24
24
  "@babel/preset-env": "^7.23.3",
25
- "@docusaurus/bundler": "0.0.0-6094",
26
- "@docusaurus/core": "0.0.0-6094",
27
- "@docusaurus/logger": "0.0.0-6094",
28
- "@docusaurus/theme-common": "0.0.0-6094",
29
- "@docusaurus/theme-translations": "0.0.0-6094",
30
- "@docusaurus/types": "0.0.0-6094",
31
- "@docusaurus/utils": "0.0.0-6094",
32
- "@docusaurus/utils-validation": "0.0.0-6094",
25
+ "@docusaurus/bundler": "0.0.0-6095",
26
+ "@docusaurus/core": "0.0.0-6095",
27
+ "@docusaurus/logger": "0.0.0-6095",
28
+ "@docusaurus/theme-common": "0.0.0-6095",
29
+ "@docusaurus/theme-translations": "0.0.0-6095",
30
+ "@docusaurus/types": "0.0.0-6095",
31
+ "@docusaurus/utils": "0.0.0-6095",
32
+ "@docusaurus/utils-validation": "0.0.0-6095",
33
33
  "babel-loader": "^9.1.3",
34
34
  "clsx": "^2.0.0",
35
35
  "core-js": "^3.31.1",
36
36
  "tslib": "^2.6.0",
37
- "webpack": "^5.88.1",
37
+ "webpack": "^5.95.0",
38
38
  "webpack-merge": "^5.9.0",
39
39
  "workbox-build": "^7.0.0",
40
40
  "workbox-precaching": "^7.0.0",
41
41
  "workbox-window": "^7.0.0"
42
42
  },
43
43
  "devDependencies": {
44
- "@docusaurus/module-type-aliases": "0.0.0-6094",
44
+ "@docusaurus/module-type-aliases": "0.0.0-6095",
45
45
  "fs-extra": "^11.1.0"
46
46
  },
47
47
  "peerDependencies": {
@@ -51,5 +51,5 @@
51
51
  "engines": {
52
52
  "node": ">=18.0"
53
53
  },
54
- "gitHead": "c2b31a8be6d238545a078faac4ee39b1b0e9d20c"
54
+ "gitHead": "c22ee69335ebddd15e83338ae51cd10a05ba4067"
55
55
  }
package/src/index.ts CHANGED
@@ -94,20 +94,15 @@ export default function pluginPWA(
94
94
  configureWebpack(config, isServer, {currentBundler}) {
95
95
  return {
96
96
  plugins: [
97
- new currentBundler.instance.EnvironmentPlugin(
98
- // See https://github.com/facebook/docusaurus/pull/10455#issuecomment-2317593528
99
- // See https://github.com/webpack/webpack/commit/adf2a6b7c6077fd806ea0e378c1450cccecc9ed0#r145989788
100
- // @ts-expect-error: bad Webpack type?
101
- {
102
- PWA_DEBUG: debug,
103
- PWA_SERVICE_WORKER_URL: path.posix.resolve(
104
- `${(config.output?.publicPath as string) || '/'}`,
105
- 'sw.js',
106
- ),
107
- PWA_OFFLINE_MODE_ACTIVATION_STRATEGIES:
108
- offlineModeActivationStrategies,
109
- },
110
- ),
97
+ new currentBundler.instance.EnvironmentPlugin({
98
+ PWA_DEBUG: debug,
99
+ PWA_SERVICE_WORKER_URL: path.posix.resolve(
100
+ `${(config.output?.publicPath as string) || '/'}`,
101
+ 'sw.js',
102
+ ),
103
+ PWA_OFFLINE_MODE_ACTIVATION_STRATEGIES:
104
+ offlineModeActivationStrategies,
105
+ }),
111
106
  ],
112
107
  };
113
108
  },