@lynx-js/rspeedy-canary 0.11.8 → 0.11.9-canary-20251104-e7d186a6
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 +61 -54
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# @lynx-js/rspeedy
|
|
2
2
|
|
|
3
|
+
## 0.11.9-canary-20251104063141-e7d186a6fcf08fecf18b5ab82b004b955bb1a2b3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies []:
|
|
8
|
+
- @lynx-js/web-rsbuild-server-middleware@0.18.3-canary-20251104063141-e7d186a6fcf08fecf18b5ab82b004b955bb1a2b3
|
|
9
|
+
|
|
3
10
|
## 0.11.8
|
|
4
11
|
|
|
5
12
|
### Patch Changes
|
|
@@ -69,11 +76,11 @@
|
|
|
69
76
|
- Support `command` and `env` parameters in the function exported by `lynx.config.js`. ([#1669](https://github.com/lynx-family/lynx-stack/pull/1669))
|
|
70
77
|
|
|
71
78
|
```js
|
|
72
|
-
import { defineConfig } from
|
|
79
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
73
80
|
|
|
74
81
|
export default defineConfig(({ command, env }) => {
|
|
75
|
-
const isBuild = command ===
|
|
76
|
-
const isTest = env ===
|
|
82
|
+
const isBuild = command === "build";
|
|
83
|
+
const isTest = env === "test";
|
|
77
84
|
|
|
78
85
|
return {
|
|
79
86
|
output: {
|
|
@@ -82,8 +89,8 @@
|
|
|
82
89
|
performance: {
|
|
83
90
|
buildCache: isBuild,
|
|
84
91
|
},
|
|
85
|
-
}
|
|
86
|
-
})
|
|
92
|
+
};
|
|
93
|
+
});
|
|
87
94
|
```
|
|
88
95
|
|
|
89
96
|
- Support `resolve.dedupe`. ([#1671](https://github.com/lynx-family/lynx-stack/pull/1671))
|
|
@@ -91,30 +98,30 @@
|
|
|
91
98
|
This is useful when having multiple duplicated packages in the bundle:
|
|
92
99
|
|
|
93
100
|
```js
|
|
94
|
-
import { defineConfig } from
|
|
101
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
95
102
|
|
|
96
103
|
export default defineConfig({
|
|
97
104
|
resolve: {
|
|
98
|
-
dedupe: [
|
|
105
|
+
dedupe: ["tslib"],
|
|
99
106
|
},
|
|
100
|
-
})
|
|
107
|
+
});
|
|
101
108
|
```
|
|
102
109
|
|
|
103
110
|
- Support `resolve.aliasStrategy` for controlling priority between `tsconfig.json` paths and `resolve.alias` ([#1722](https://github.com/lynx-family/lynx-stack/pull/1722))
|
|
104
111
|
|
|
105
112
|
```js
|
|
106
|
-
import { defineConfig } from
|
|
113
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
107
114
|
|
|
108
115
|
export default defineConfig({
|
|
109
116
|
resolve: {
|
|
110
117
|
alias: {
|
|
111
|
-
|
|
118
|
+
"@": "./src",
|
|
112
119
|
},
|
|
113
120
|
// 'prefer-tsconfig' (default): tsconfig.json paths take priority
|
|
114
121
|
// 'prefer-alias': resolve.alias takes priority
|
|
115
|
-
aliasStrategy:
|
|
122
|
+
aliasStrategy: "prefer-alias",
|
|
116
123
|
},
|
|
117
|
-
})
|
|
124
|
+
});
|
|
118
125
|
```
|
|
119
126
|
|
|
120
127
|
- Bump Rsbuild v1.5.4 with Rspack v1.5.2. ([#1644](https://github.com/lynx-family/lynx-stack/pull/1644))
|
|
@@ -134,7 +141,7 @@
|
|
|
134
141
|
- Add `output.dataUriLimit.*` for fine-grained control of asset inlining. ([#1648](https://github.com/lynx-family/lynx-stack/pull/1648))
|
|
135
142
|
|
|
136
143
|
```js
|
|
137
|
-
import { defineConfig } from
|
|
144
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
138
145
|
|
|
139
146
|
export default defineConfig({
|
|
140
147
|
output: {
|
|
@@ -143,7 +150,7 @@
|
|
|
143
150
|
media: 0,
|
|
144
151
|
},
|
|
145
152
|
},
|
|
146
|
-
})
|
|
153
|
+
});
|
|
147
154
|
```
|
|
148
155
|
|
|
149
156
|
## 0.11.0
|
|
@@ -263,28 +270,28 @@
|
|
|
263
270
|
|
|
264
271
|
```ts
|
|
265
272
|
type InlineChunkTestFunction = (params: {
|
|
266
|
-
size: number
|
|
267
|
-
name: string
|
|
268
|
-
}) => boolean
|
|
273
|
+
size: number;
|
|
274
|
+
name: string;
|
|
275
|
+
}) => boolean;
|
|
269
276
|
|
|
270
|
-
type InlineChunkTest = RegExp | InlineChunkTestFunction
|
|
277
|
+
type InlineChunkTest = RegExp | InlineChunkTestFunction;
|
|
271
278
|
|
|
272
279
|
type InlineChunkConfig =
|
|
273
280
|
| boolean
|
|
274
281
|
| InlineChunkTest
|
|
275
|
-
| { enable?: boolean |
|
|
282
|
+
| { enable?: boolean | "auto"; test: InlineChunkTest };
|
|
276
283
|
```
|
|
277
284
|
|
|
278
285
|
```ts
|
|
279
|
-
import { defineConfig } from
|
|
286
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
280
287
|
|
|
281
288
|
export default defineConfig({
|
|
282
289
|
output: {
|
|
283
290
|
inlineScripts: ({ name, size }) => {
|
|
284
|
-
return name.includes(
|
|
291
|
+
return name.includes("foo") && size < 1000;
|
|
285
292
|
},
|
|
286
293
|
},
|
|
287
|
-
})
|
|
294
|
+
});
|
|
288
295
|
```
|
|
289
296
|
|
|
290
297
|
- docs: remove chunks: 'all' in comments ([#1168](https://github.com/lynx-family/lynx-stack/pull/1168))
|
|
@@ -327,13 +334,13 @@
|
|
|
327
334
|
example:
|
|
328
335
|
|
|
329
336
|
```js
|
|
330
|
-
import { defineConfig } from
|
|
337
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
331
338
|
|
|
332
339
|
export default defineConfig({
|
|
333
340
|
output: {
|
|
334
341
|
inlineScripts: false,
|
|
335
342
|
},
|
|
336
|
-
})
|
|
343
|
+
});
|
|
337
344
|
```
|
|
338
345
|
|
|
339
346
|
- Bump Rsbuild v1.3.21 with Rspack v1.3.11. ([#863](https://github.com/lynx-family/lynx-stack/pull/863))
|
|
@@ -353,12 +360,12 @@
|
|
|
353
360
|
example:
|
|
354
361
|
|
|
355
362
|
```js
|
|
356
|
-
import { defineConfig } from
|
|
363
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
357
364
|
export default defineConfig({
|
|
358
365
|
source: {
|
|
359
|
-
preEntry:
|
|
366
|
+
preEntry: "./src/polyfill.ts",
|
|
360
367
|
},
|
|
361
|
-
})
|
|
368
|
+
});
|
|
362
369
|
```
|
|
363
370
|
|
|
364
371
|
- Bump Rsbuild v1.3.20 with Rspack v1.3.10. ([#799](https://github.com/lynx-family/lynx-stack/pull/799))
|
|
@@ -369,17 +376,17 @@
|
|
|
369
376
|
|
|
370
377
|
```js
|
|
371
378
|
export const myPlugin = {
|
|
372
|
-
name:
|
|
379
|
+
name: "my-plugin",
|
|
373
380
|
setup(api) {
|
|
374
|
-
const { callerName } = api.context
|
|
381
|
+
const { callerName } = api.context;
|
|
375
382
|
|
|
376
|
-
if (callerName ===
|
|
383
|
+
if (callerName === "rslib") {
|
|
377
384
|
// ...
|
|
378
|
-
} else if (callerName ===
|
|
385
|
+
} else if (callerName === "rspeedy") {
|
|
379
386
|
// ...
|
|
380
387
|
}
|
|
381
388
|
},
|
|
382
|
-
}
|
|
389
|
+
};
|
|
383
390
|
```
|
|
384
391
|
|
|
385
392
|
- Support `performance.buildCache`. ([#766](https://github.com/lynx-family/lynx-stack/pull/766))
|
|
@@ -402,7 +409,7 @@
|
|
|
402
409
|
Set `tools.rsdoctor.experiments.enableNativePlugin` to `false` to use the old JS plugin.
|
|
403
410
|
|
|
404
411
|
```js
|
|
405
|
-
import { defineConfig } from
|
|
412
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
406
413
|
|
|
407
414
|
export default defineConfig({
|
|
408
415
|
tools: {
|
|
@@ -412,7 +419,7 @@
|
|
|
412
419
|
},
|
|
413
420
|
},
|
|
414
421
|
},
|
|
415
|
-
})
|
|
422
|
+
});
|
|
416
423
|
```
|
|
417
424
|
|
|
418
425
|
See [Rsdoctor - 1.0](https://rsdoctor.dev/blog/release/release-note-1_0#-faster-analysis) for more details.
|
|
@@ -544,12 +551,12 @@
|
|
|
544
551
|
example:
|
|
545
552
|
|
|
546
553
|
```js
|
|
547
|
-
import { defineConfig } from
|
|
554
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
548
555
|
export default defineConfig({
|
|
549
556
|
server: {
|
|
550
|
-
base:
|
|
557
|
+
base: "/dist",
|
|
551
558
|
},
|
|
552
|
-
})
|
|
559
|
+
});
|
|
553
560
|
```
|
|
554
561
|
|
|
555
562
|
- Updated dependencies [[`b026c8b`](https://github.com/lynx-family/lynx-stack/commit/b026c8bdcbf7bdcda73e170477297213b447d876)]:
|
|
@@ -602,11 +609,11 @@
|
|
|
602
609
|
You can switch to other tools by using:
|
|
603
610
|
|
|
604
611
|
```js
|
|
605
|
-
import { defineConfig } from
|
|
612
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
606
613
|
import {
|
|
607
614
|
CssMinimizerWebpackPlugin,
|
|
608
615
|
pluginCssMinimizer,
|
|
609
|
-
} from
|
|
616
|
+
} from "@rsbuild/plugin-css-minimizer";
|
|
610
617
|
|
|
611
618
|
export default defineConfig({
|
|
612
619
|
plugins: [
|
|
@@ -619,7 +626,7 @@
|
|
|
619
626
|
},
|
|
620
627
|
}),
|
|
621
628
|
],
|
|
622
|
-
})
|
|
629
|
+
});
|
|
623
630
|
```
|
|
624
631
|
|
|
625
632
|
See [@rsbuild/plugin-css-minimizer](https://github.com/rspack-contrib/rsbuild-plugin-css-minimizer) for details.
|
|
@@ -629,8 +636,8 @@
|
|
|
629
636
|
You can use custom options with [@rsbuild/plugin-css-minimizer](https://github.com/rspack-contrib/rsbuild-plugin-css-minimizer):
|
|
630
637
|
|
|
631
638
|
```js
|
|
632
|
-
import { defineConfig } from
|
|
633
|
-
import { pluginCssMinimizer } from
|
|
639
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
640
|
+
import { pluginCssMinimizer } from "@rsbuild/plugin-css-minimizer";
|
|
634
641
|
|
|
635
642
|
export default defineConfig({
|
|
636
643
|
plugins: [
|
|
@@ -642,7 +649,7 @@
|
|
|
642
649
|
},
|
|
643
650
|
}),
|
|
644
651
|
],
|
|
645
|
-
})
|
|
652
|
+
});
|
|
646
653
|
```
|
|
647
654
|
|
|
648
655
|
## 0.7.1
|
|
@@ -662,7 +669,7 @@
|
|
|
662
669
|
You may turn it off using `output.minify.css: false`:
|
|
663
670
|
|
|
664
671
|
```js
|
|
665
|
-
import { defineConfig } from
|
|
672
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
666
673
|
|
|
667
674
|
export default defineConfig({
|
|
668
675
|
output: {
|
|
@@ -670,18 +677,18 @@
|
|
|
670
677
|
css: false,
|
|
671
678
|
},
|
|
672
679
|
},
|
|
673
|
-
})
|
|
680
|
+
});
|
|
674
681
|
```
|
|
675
682
|
|
|
676
683
|
Or you may use [@rsbuild/plugin-css-minimizer](https://github.com/rspack-contrib/rsbuild-plugin-css-minimizer) to use `cssnano` as CSS minimizer.
|
|
677
684
|
|
|
678
685
|
```js
|
|
679
|
-
import { defineConfig } from
|
|
680
|
-
import { pluginCssMinimizer } from
|
|
686
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
687
|
+
import { pluginCssMinimizer } from "@rsbuild/plugin-css-minimizer";
|
|
681
688
|
|
|
682
689
|
export default defineConfig({
|
|
683
690
|
plugins: [pluginCssMinimizer()],
|
|
684
|
-
})
|
|
691
|
+
});
|
|
685
692
|
```
|
|
686
693
|
|
|
687
694
|
- 525554c: **BREAKING CHANGE**: Bump ts-blank-space to ^0.6.0.
|
|
@@ -708,22 +715,22 @@
|
|
|
708
715
|
- The new `type: 'reload-server'` will restart the development server when it detects changes in the specified files.
|
|
709
716
|
|
|
710
717
|
```js
|
|
711
|
-
import { defineConfig } from
|
|
718
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
712
719
|
|
|
713
720
|
export default defineConfig({
|
|
714
721
|
dev: {
|
|
715
722
|
watchFiles: [
|
|
716
723
|
{
|
|
717
|
-
type:
|
|
718
|
-
paths: [
|
|
724
|
+
type: "reload-server",
|
|
725
|
+
paths: ["public/**/*.txt"],
|
|
719
726
|
},
|
|
720
727
|
{
|
|
721
|
-
type:
|
|
722
|
-
paths: [
|
|
728
|
+
type: "reload-page",
|
|
729
|
+
paths: ["public/**/*.json"],
|
|
723
730
|
},
|
|
724
731
|
],
|
|
725
732
|
},
|
|
726
|
-
})
|
|
733
|
+
});
|
|
727
734
|
```
|
|
728
735
|
|
|
729
736
|
- be9b003: Add `source.exclude`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lynx-js/rspeedy-canary",
|
|
3
|
-
"version": "0.11.
|
|
3
|
+
"version": "0.11.9-canary-20251104-e7d186a6",
|
|
4
4
|
"description": "A webpack/rspack-based frontend toolchain for Lynx",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"webpack",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"dependencies": {
|
|
51
51
|
"@lynx-js/cache-events-webpack-plugin": "npm:@lynx-js/cache-events-webpack-plugin-canary@0.0.2",
|
|
52
52
|
"@lynx-js/chunk-loading-webpack-plugin": "npm:@lynx-js/chunk-loading-webpack-plugin-canary@0.3.3",
|
|
53
|
-
"@lynx-js/web-rsbuild-server-middleware": "npm:@lynx-js/web-rsbuild-server-middleware-canary@0.18.
|
|
53
|
+
"@lynx-js/web-rsbuild-server-middleware": "npm:@lynx-js/web-rsbuild-server-middleware-canary@0.18.3-canary-20251104-e7d186a6",
|
|
54
54
|
"@lynx-js/webpack-dev-transport": "npm:@lynx-js/webpack-dev-transport-canary@0.2.0",
|
|
55
55
|
"@lynx-js/websocket": "npm:@lynx-js/websocket-canary@0.0.4",
|
|
56
56
|
"@rsbuild/core": "1.5.17",
|