@lynx-js/rspeedy-canary 0.10.1-canary-20250708-671a7a98 → 0.10.1-canary-20250708-0a3c89d5

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/CHANGELOG.md CHANGED
@@ -1,6 +1,13 @@
1
1
  # @lynx-js/rspeedy
2
2
 
3
- ## 0.10.1-canary-20250708140128-671a7a98d81ab4002d6a88ce64e568f2e41af2e7
3
+ ## 0.10.1-canary-20250708175607-0a3c89d5776009d1f32d444e77be834fa2b79645
4
+
5
+ ### Patch Changes
6
+
7
+ - Bump Rsbuild v1.4.5 with Rspack v1.4.5 ([#1239](https://github.com/lynx-family/lynx-stack/pull/1239))
8
+
9
+ - Updated dependencies [[`0a3c89d`](https://github.com/lynx-family/lynx-stack/commit/0a3c89d5776009d1f32d444e77be834fa2b79645)]:
10
+ - @lynx-js/webpack-dev-transport@0.2.0-canary-20250708175607-0a3c89d5776009d1f32d444e77be834fa2b79645
4
11
 
5
12
  ## 0.10.0
6
13
 
@@ -14,21 +14,6 @@ export const __webpack_modules__ = {
14
14
  var picocolors = __webpack_require__("../../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js");
15
15
  var picocolors_default = /*#__PURE__*/ __webpack_require__.n(picocolors);
16
16
  var debug = __webpack_require__("./src/debug.ts");
17
- class CompilationIdPlugin {
18
- apply(compiler) {
19
- compiler.hooks.initialize.tap('CompilationIdPlugin', ()=>{
20
- const { DefinePlugin } = compiler.webpack;
21
- new DefinePlugin({
22
- RSPEEDY_COMPILATION_ID: JSON.stringify(getCompilationId(compiler))
23
- }).apply(compiler);
24
- });
25
- }
26
- }
27
- const COMPILATION_ID_REGEX = /[^\w-]/g;
28
- function getCompilationId(compiler) {
29
- const uniqueName = compiler.options.output.uniqueName ?? '';
30
- return `${compiler.name ?? ''}_${uniqueName.replace(COMPILATION_ID_REGEX, '_')}`;
31
- }
32
17
  class ProvidePlugin_ProvidePlugin {
33
18
  definitions;
34
19
  constructor(definitions){
@@ -78,10 +63,19 @@ export const __webpack_modules__ = {
78
63
  }
79
64
  }));
80
65
  const require = (0, external_node_module_.createRequire)(import.meta.url);
81
- api.modifyBundlerChain((chain, { isProd })=>{
66
+ api.modifyBundlerChain((chain, { isProd, environment })=>{
82
67
  if (isProd) return;
83
68
  const rsbuildPath = require.resolve('@rsbuild/core');
84
69
  const rspeedyDir = external_node_path_["default"].dirname(require.resolve('@lynx-js/rspeedy/package.json'));
70
+ const searchParams = new URLSearchParams({
71
+ hostname,
72
+ port: api.context.devServer?.port?.toString() ?? '',
73
+ pathname: '/rsbuild-hmr',
74
+ hot: options?.hmr ?? true ? 'true' : 'false',
75
+ 'live-reload': options?.liveReload ?? true ? 'true' : 'false',
76
+ protocol: 'ws'
77
+ });
78
+ if (environment.webSocketToken) searchParams.set('token', environment.webSocketToken);
85
79
  chain.resolve.alias.set('webpack/hot/log.js', require.resolve('@rspack/core/hot/log', {
86
80
  paths: [
87
81
  rsbuildPath
@@ -90,7 +84,7 @@ export const __webpack_modules__ = {
90
84
  paths: [
91
85
  rsbuildPath
92
86
  ]
93
- })).set('@lynx-js/webpack-dev-transport/client', `${require.resolve('@lynx-js/webpack-dev-transport/client')}?hostname=${hostname}&port=${api.context.devServer?.port}&pathname=/rsbuild-hmr&hot=${options?.hmr ?? true}&live-reload=${options?.liveReload ?? true}&protocol=ws`).set('@rspack/core/hot/dev-server', require.resolve('@rspack/core/hot/dev-server', {
87
+ })).set('@lynx-js/webpack-dev-transport/client', `${require.resolve('@lynx-js/webpack-dev-transport/client')}?${searchParams.toString()}`).set('@rspack/core/hot/dev-server', require.resolve('@rspack/core/hot/dev-server', {
94
88
  paths: [
95
89
  rsbuildPath
96
90
  ]
@@ -109,7 +103,7 @@ export const __webpack_modules__ = {
109
103
  'default'
110
104
  ]
111
105
  }
112
- ]).end().plugin('lynx.hmr.compilation-id').use(CompilationIdPlugin, []).end();
106
+ ]).end();
113
107
  });
114
108
  }
115
109
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lynx-js/rspeedy-canary",
3
- "version": "0.10.1-canary-20250708-671a7a98",
3
+ "version": "0.10.1-canary-20250708-0a3c89d5",
4
4
  "description": "A webpack/rspack-based frontend toolchain for Lynx",
5
5
  "keywords": [
6
6
  "webpack",
@@ -47,9 +47,9 @@
47
47
  ],
48
48
  "dependencies": {
49
49
  "@lynx-js/chunk-loading-webpack-plugin": "npm:@lynx-js/chunk-loading-webpack-plugin-canary@0.3.0",
50
- "@lynx-js/webpack-dev-transport": "npm:@lynx-js/webpack-dev-transport-canary@0.1.3",
50
+ "@lynx-js/webpack-dev-transport": "npm:@lynx-js/webpack-dev-transport-canary@0.2.0-canary-20250708-0a3c89d5",
51
51
  "@lynx-js/websocket": "npm:@lynx-js/websocket-canary@0.0.4",
52
- "@rsbuild/core": "1.4.3",
52
+ "@rsbuild/core": "1.4.5",
53
53
  "@rsbuild/plugin-css-minimizer": "1.0.2",
54
54
  "@rsdoctor/rspack-plugin": "1.1.7"
55
55
  },