@lynx-js/rspeedy-canary 0.13.0 → 0.13.1-canary-20260112-6c2b51a6
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.13.1-canary-20260112091442-6c2b51a661ae244eb40671f63f29ee971e084ed4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies []:
|
|
8
|
+
- @lynx-js/web-rsbuild-server-middleware@0.19.6-canary-20260112091442-6c2b51a661ae244eb40671f63f29ee971e084ed4
|
|
9
|
+
|
|
3
10
|
## 0.13.0
|
|
4
11
|
|
|
5
12
|
### Minor Changes
|
|
@@ -149,11 +156,11 @@
|
|
|
149
156
|
- Support `command` and `env` parameters in the function exported by `lynx.config.js`. ([#1669](https://github.com/lynx-family/lynx-stack/pull/1669))
|
|
150
157
|
|
|
151
158
|
```js
|
|
152
|
-
import { defineConfig } from
|
|
159
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
153
160
|
|
|
154
161
|
export default defineConfig(({ command, env }) => {
|
|
155
|
-
const isBuild = command ===
|
|
156
|
-
const isTest = env ===
|
|
162
|
+
const isBuild = command === "build";
|
|
163
|
+
const isTest = env === "test";
|
|
157
164
|
|
|
158
165
|
return {
|
|
159
166
|
output: {
|
|
@@ -162,8 +169,8 @@
|
|
|
162
169
|
performance: {
|
|
163
170
|
buildCache: isBuild,
|
|
164
171
|
},
|
|
165
|
-
}
|
|
166
|
-
})
|
|
172
|
+
};
|
|
173
|
+
});
|
|
167
174
|
```
|
|
168
175
|
|
|
169
176
|
- Support `resolve.dedupe`. ([#1671](https://github.com/lynx-family/lynx-stack/pull/1671))
|
|
@@ -171,30 +178,30 @@
|
|
|
171
178
|
This is useful when having multiple duplicated packages in the bundle:
|
|
172
179
|
|
|
173
180
|
```js
|
|
174
|
-
import { defineConfig } from
|
|
181
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
175
182
|
|
|
176
183
|
export default defineConfig({
|
|
177
184
|
resolve: {
|
|
178
|
-
dedupe: [
|
|
185
|
+
dedupe: ["tslib"],
|
|
179
186
|
},
|
|
180
|
-
})
|
|
187
|
+
});
|
|
181
188
|
```
|
|
182
189
|
|
|
183
190
|
- Support `resolve.aliasStrategy` for controlling priority between `tsconfig.json` paths and `resolve.alias` ([#1722](https://github.com/lynx-family/lynx-stack/pull/1722))
|
|
184
191
|
|
|
185
192
|
```js
|
|
186
|
-
import { defineConfig } from
|
|
193
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
187
194
|
|
|
188
195
|
export default defineConfig({
|
|
189
196
|
resolve: {
|
|
190
197
|
alias: {
|
|
191
|
-
|
|
198
|
+
"@": "./src",
|
|
192
199
|
},
|
|
193
200
|
// 'prefer-tsconfig' (default): tsconfig.json paths take priority
|
|
194
201
|
// 'prefer-alias': resolve.alias takes priority
|
|
195
|
-
aliasStrategy:
|
|
202
|
+
aliasStrategy: "prefer-alias",
|
|
196
203
|
},
|
|
197
|
-
})
|
|
204
|
+
});
|
|
198
205
|
```
|
|
199
206
|
|
|
200
207
|
- Bump Rsbuild v1.5.4 with Rspack v1.5.2. ([#1644](https://github.com/lynx-family/lynx-stack/pull/1644))
|
|
@@ -214,7 +221,7 @@
|
|
|
214
221
|
- Add `output.dataUriLimit.*` for fine-grained control of asset inlining. ([#1648](https://github.com/lynx-family/lynx-stack/pull/1648))
|
|
215
222
|
|
|
216
223
|
```js
|
|
217
|
-
import { defineConfig } from
|
|
224
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
218
225
|
|
|
219
226
|
export default defineConfig({
|
|
220
227
|
output: {
|
|
@@ -223,7 +230,7 @@
|
|
|
223
230
|
media: 0,
|
|
224
231
|
},
|
|
225
232
|
},
|
|
226
|
-
})
|
|
233
|
+
});
|
|
227
234
|
```
|
|
228
235
|
|
|
229
236
|
## 0.11.0
|
|
@@ -343,28 +350,28 @@
|
|
|
343
350
|
|
|
344
351
|
```ts
|
|
345
352
|
type InlineChunkTestFunction = (params: {
|
|
346
|
-
size: number
|
|
347
|
-
name: string
|
|
348
|
-
}) => boolean
|
|
353
|
+
size: number;
|
|
354
|
+
name: string;
|
|
355
|
+
}) => boolean;
|
|
349
356
|
|
|
350
|
-
type InlineChunkTest = RegExp | InlineChunkTestFunction
|
|
357
|
+
type InlineChunkTest = RegExp | InlineChunkTestFunction;
|
|
351
358
|
|
|
352
359
|
type InlineChunkConfig =
|
|
353
360
|
| boolean
|
|
354
361
|
| InlineChunkTest
|
|
355
|
-
| { enable?: boolean |
|
|
362
|
+
| { enable?: boolean | "auto"; test: InlineChunkTest };
|
|
356
363
|
```
|
|
357
364
|
|
|
358
365
|
```ts
|
|
359
|
-
import { defineConfig } from
|
|
366
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
360
367
|
|
|
361
368
|
export default defineConfig({
|
|
362
369
|
output: {
|
|
363
370
|
inlineScripts: ({ name, size }) => {
|
|
364
|
-
return name.includes(
|
|
371
|
+
return name.includes("foo") && size < 1000;
|
|
365
372
|
},
|
|
366
373
|
},
|
|
367
|
-
})
|
|
374
|
+
});
|
|
368
375
|
```
|
|
369
376
|
|
|
370
377
|
- docs: remove chunks: 'all' in comments ([#1168](https://github.com/lynx-family/lynx-stack/pull/1168))
|
|
@@ -407,13 +414,13 @@
|
|
|
407
414
|
example:
|
|
408
415
|
|
|
409
416
|
```js
|
|
410
|
-
import { defineConfig } from
|
|
417
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
411
418
|
|
|
412
419
|
export default defineConfig({
|
|
413
420
|
output: {
|
|
414
421
|
inlineScripts: false,
|
|
415
422
|
},
|
|
416
|
-
})
|
|
423
|
+
});
|
|
417
424
|
```
|
|
418
425
|
|
|
419
426
|
- Bump Rsbuild v1.3.21 with Rspack v1.3.11. ([#863](https://github.com/lynx-family/lynx-stack/pull/863))
|
|
@@ -433,12 +440,12 @@
|
|
|
433
440
|
example:
|
|
434
441
|
|
|
435
442
|
```js
|
|
436
|
-
import { defineConfig } from
|
|
443
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
437
444
|
export default defineConfig({
|
|
438
445
|
source: {
|
|
439
|
-
preEntry:
|
|
446
|
+
preEntry: "./src/polyfill.ts",
|
|
440
447
|
},
|
|
441
|
-
})
|
|
448
|
+
});
|
|
442
449
|
```
|
|
443
450
|
|
|
444
451
|
- Bump Rsbuild v1.3.20 with Rspack v1.3.10. ([#799](https://github.com/lynx-family/lynx-stack/pull/799))
|
|
@@ -449,17 +456,17 @@
|
|
|
449
456
|
|
|
450
457
|
```js
|
|
451
458
|
export const myPlugin = {
|
|
452
|
-
name:
|
|
459
|
+
name: "my-plugin",
|
|
453
460
|
setup(api) {
|
|
454
|
-
const { callerName } = api.context
|
|
461
|
+
const { callerName } = api.context;
|
|
455
462
|
|
|
456
|
-
if (callerName ===
|
|
463
|
+
if (callerName === "rslib") {
|
|
457
464
|
// ...
|
|
458
|
-
} else if (callerName ===
|
|
465
|
+
} else if (callerName === "rspeedy") {
|
|
459
466
|
// ...
|
|
460
467
|
}
|
|
461
468
|
},
|
|
462
|
-
}
|
|
469
|
+
};
|
|
463
470
|
```
|
|
464
471
|
|
|
465
472
|
- Support `performance.buildCache`. ([#766](https://github.com/lynx-family/lynx-stack/pull/766))
|
|
@@ -482,7 +489,7 @@
|
|
|
482
489
|
Set `tools.rsdoctor.experiments.enableNativePlugin` to `false` to use the old JS plugin.
|
|
483
490
|
|
|
484
491
|
```js
|
|
485
|
-
import { defineConfig } from
|
|
492
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
486
493
|
|
|
487
494
|
export default defineConfig({
|
|
488
495
|
tools: {
|
|
@@ -492,7 +499,7 @@
|
|
|
492
499
|
},
|
|
493
500
|
},
|
|
494
501
|
},
|
|
495
|
-
})
|
|
502
|
+
});
|
|
496
503
|
```
|
|
497
504
|
|
|
498
505
|
See [Rsdoctor - 1.0](https://rsdoctor.dev/blog/release/release-note-1_0#-faster-analysis) for more details.
|
|
@@ -624,12 +631,12 @@
|
|
|
624
631
|
example:
|
|
625
632
|
|
|
626
633
|
```js
|
|
627
|
-
import { defineConfig } from
|
|
634
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
628
635
|
export default defineConfig({
|
|
629
636
|
server: {
|
|
630
|
-
base:
|
|
637
|
+
base: "/dist",
|
|
631
638
|
},
|
|
632
|
-
})
|
|
639
|
+
});
|
|
633
640
|
```
|
|
634
641
|
|
|
635
642
|
- Updated dependencies [[`b026c8b`](https://github.com/lynx-family/lynx-stack/commit/b026c8bdcbf7bdcda73e170477297213b447d876)]:
|
|
@@ -682,11 +689,11 @@
|
|
|
682
689
|
You can switch to other tools by using:
|
|
683
690
|
|
|
684
691
|
```js
|
|
685
|
-
import { defineConfig } from
|
|
692
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
686
693
|
import {
|
|
687
694
|
CssMinimizerWebpackPlugin,
|
|
688
695
|
pluginCssMinimizer,
|
|
689
|
-
} from
|
|
696
|
+
} from "@rsbuild/plugin-css-minimizer";
|
|
690
697
|
|
|
691
698
|
export default defineConfig({
|
|
692
699
|
plugins: [
|
|
@@ -699,7 +706,7 @@
|
|
|
699
706
|
},
|
|
700
707
|
}),
|
|
701
708
|
],
|
|
702
|
-
})
|
|
709
|
+
});
|
|
703
710
|
```
|
|
704
711
|
|
|
705
712
|
See [@rsbuild/plugin-css-minimizer](https://github.com/rspack-contrib/rsbuild-plugin-css-minimizer) for details.
|
|
@@ -709,8 +716,8 @@
|
|
|
709
716
|
You can use custom options with [@rsbuild/plugin-css-minimizer](https://github.com/rspack-contrib/rsbuild-plugin-css-minimizer):
|
|
710
717
|
|
|
711
718
|
```js
|
|
712
|
-
import { defineConfig } from
|
|
713
|
-
import { pluginCssMinimizer } from
|
|
719
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
720
|
+
import { pluginCssMinimizer } from "@rsbuild/plugin-css-minimizer";
|
|
714
721
|
|
|
715
722
|
export default defineConfig({
|
|
716
723
|
plugins: [
|
|
@@ -722,7 +729,7 @@
|
|
|
722
729
|
},
|
|
723
730
|
}),
|
|
724
731
|
],
|
|
725
|
-
})
|
|
732
|
+
});
|
|
726
733
|
```
|
|
727
734
|
|
|
728
735
|
## 0.7.1
|
|
@@ -742,7 +749,7 @@
|
|
|
742
749
|
You may turn it off using `output.minify.css: false`:
|
|
743
750
|
|
|
744
751
|
```js
|
|
745
|
-
import { defineConfig } from
|
|
752
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
746
753
|
|
|
747
754
|
export default defineConfig({
|
|
748
755
|
output: {
|
|
@@ -750,18 +757,18 @@
|
|
|
750
757
|
css: false,
|
|
751
758
|
},
|
|
752
759
|
},
|
|
753
|
-
})
|
|
760
|
+
});
|
|
754
761
|
```
|
|
755
762
|
|
|
756
763
|
Or you may use [@rsbuild/plugin-css-minimizer](https://github.com/rspack-contrib/rsbuild-plugin-css-minimizer) to use `cssnano` as CSS minimizer.
|
|
757
764
|
|
|
758
765
|
```js
|
|
759
|
-
import { defineConfig } from
|
|
760
|
-
import { pluginCssMinimizer } from
|
|
766
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
767
|
+
import { pluginCssMinimizer } from "@rsbuild/plugin-css-minimizer";
|
|
761
768
|
|
|
762
769
|
export default defineConfig({
|
|
763
770
|
plugins: [pluginCssMinimizer()],
|
|
764
|
-
})
|
|
771
|
+
});
|
|
765
772
|
```
|
|
766
773
|
|
|
767
774
|
- 525554c: **BREAKING CHANGE**: Bump ts-blank-space to ^0.6.0.
|
|
@@ -788,22 +795,22 @@
|
|
|
788
795
|
- The new `type: 'reload-server'` will restart the development server when it detects changes in the specified files.
|
|
789
796
|
|
|
790
797
|
```js
|
|
791
|
-
import { defineConfig } from
|
|
798
|
+
import { defineConfig } from "@lynx-js/rspeedy";
|
|
792
799
|
|
|
793
800
|
export default defineConfig({
|
|
794
801
|
dev: {
|
|
795
802
|
watchFiles: [
|
|
796
803
|
{
|
|
797
|
-
type:
|
|
798
|
-
paths: [
|
|
804
|
+
type: "reload-server",
|
|
805
|
+
paths: ["public/**/*.txt"],
|
|
799
806
|
},
|
|
800
807
|
{
|
|
801
|
-
type:
|
|
802
|
-
paths: [
|
|
808
|
+
type: "reload-page",
|
|
809
|
+
paths: ["public/**/*.json"],
|
|
803
810
|
},
|
|
804
811
|
],
|
|
805
812
|
},
|
|
806
|
-
})
|
|
813
|
+
});
|
|
807
814
|
```
|
|
808
815
|
|
|
809
816
|
- be9b003: Add `source.exclude`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lynx-js/rspeedy-canary",
|
|
3
|
-
"version": "0.13.
|
|
3
|
+
"version": "0.13.1-canary-20260112-6c2b51a6",
|
|
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.19.
|
|
53
|
+
"@lynx-js/web-rsbuild-server-middleware": "npm:@lynx-js/web-rsbuild-server-middleware-canary@0.19.6-canary-20260112-6c2b51a6",
|
|
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.7.1",
|