@appshell/webpack-plugin 1.0.0-alpha.77 → 1.0.0-alpha.78

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.
@@ -17,18 +17,20 @@ type DevServerOptions = {
17
17
  [index: string]: unknown;
18
18
  } | false | undefined;
19
19
  /**
20
- * Whether this dev server's hot-reload client has an address it can actually dial.
20
+ * Whether this dev server's hot-reload client has an address a browser can actually dial.
21
21
  *
22
- * Left unset, webpack-dev-server bakes its own **bind** address into the client it
23
- * serves. A server listening on every interface therefore tells its client to connect to
24
- * `0.0.0.0`, which nothing can open a socket to — measured, not inferred. Hot reload then
25
- * fails silently: the bundle renders and edits never arrive, with no error to say why.
22
+ * webpack-dev-server normalizes `client.webSocketURL` into an object before a plugin ever
23
+ * sees it, filling the hostname from whatever the server **bound**. So a server listening
24
+ * on every interface hands its client `0.0.0.0`, which nothing can open a socket to, and
25
+ * asking whether the option is *set* cannot tell that apart from a deliberate choice
26
+ * it is always set. The dialable address is the property that matters, so that is what is
27
+ * checked, against the same host list `devServerOrigin` already rejects for the same
28
+ * reason one line down.
26
29
  *
27
- * It matters more here than it would elsewhere. A remote is loaded into a shell on
28
- * another origin, so there is no page-relative address to fall back to — and a silent
29
- * failure is the worst available outcome for the one feature a dev server exists for.
30
+ * The cost of getting this wrong is silence: the bundle renders, the server reports a
31
+ * successful recompile, and edits never arrive.
30
32
  */
31
- export declare const hotSocketIsPinned: (devServer: DevServerOptions) => boolean;
33
+ export declare const hotSocketIsDialable: (devServer: DevServerOptions) => boolean;
32
34
  export declare const devServerOrigin: (devServer: DevServerOptions) => string | undefined;
33
35
  /**
34
36
  * Records where this package is being served from while a dev server is running, so tooling
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@appshell/webpack-plugin",
3
- "version": "1.0.0-alpha.77",
3
+ "version": "1.0.0-alpha.78",
4
4
  "description": "Webpack plugin used to generate a global Appshell configuration for micro-frontends built with Module Federation",
5
5
  "main": "dist/main.js",
6
6
  "types": "dist/types/webpack-plugin/src/index.d.ts",
@@ -33,8 +33,8 @@
33
33
  "plugin"
34
34
  ],
35
35
  "license": "MIT",
36
- "gitHead": "c8dda02034b57d8faec9943b6406b7c299876c40",
36
+ "gitHead": "c6076b31be149236af9073e96de1739884bfc964",
37
37
  "dependencies": {
38
- "@appshell/tokens": "^1.0.0-alpha.77"
38
+ "@appshell/tokens": "^1.0.0-alpha.78"
39
39
  }
40
40
  }