@lynx-js/rspeedy-canary 0.11.6-canary-20251012-dd7c14a8 → 0.11.6
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 +55 -55
- package/dist/1~src_cli_commands_ts.js +1 -1
- package/dist/1~src_version_ts.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @lynx-js/rspeedy
|
|
2
2
|
|
|
3
|
-
## 0.11.6
|
|
3
|
+
## 0.11.6
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
@@ -45,11 +45,11 @@
|
|
|
45
45
|
- Support `command` and `env` parameters in the function exported by `lynx.config.js`. ([#1669](https://github.com/lynx-family/lynx-stack/pull/1669))
|
|
46
46
|
|
|
47
47
|
```js
|
|
48
|
-
import { defineConfig } from
|
|
48
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
49
49
|
|
|
50
50
|
export default defineConfig(({ command, env }) => {
|
|
51
|
-
const isBuild = command ===
|
|
52
|
-
const isTest = env ===
|
|
51
|
+
const isBuild = command === 'build'
|
|
52
|
+
const isTest = env === 'test'
|
|
53
53
|
|
|
54
54
|
return {
|
|
55
55
|
output: {
|
|
@@ -58,8 +58,8 @@
|
|
|
58
58
|
performance: {
|
|
59
59
|
buildCache: isBuild,
|
|
60
60
|
},
|
|
61
|
-
}
|
|
62
|
-
})
|
|
61
|
+
}
|
|
62
|
+
})
|
|
63
63
|
```
|
|
64
64
|
|
|
65
65
|
- Support `resolve.dedupe`. ([#1671](https://github.com/lynx-family/lynx-stack/pull/1671))
|
|
@@ -67,30 +67,30 @@
|
|
|
67
67
|
This is useful when having multiple duplicated packages in the bundle:
|
|
68
68
|
|
|
69
69
|
```js
|
|
70
|
-
import { defineConfig } from
|
|
70
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
71
71
|
|
|
72
72
|
export default defineConfig({
|
|
73
73
|
resolve: {
|
|
74
|
-
dedupe: [
|
|
74
|
+
dedupe: ['tslib'],
|
|
75
75
|
},
|
|
76
|
-
})
|
|
76
|
+
})
|
|
77
77
|
```
|
|
78
78
|
|
|
79
79
|
- Support `resolve.aliasStrategy` for controlling priority between `tsconfig.json` paths and `resolve.alias` ([#1722](https://github.com/lynx-family/lynx-stack/pull/1722))
|
|
80
80
|
|
|
81
81
|
```js
|
|
82
|
-
import { defineConfig } from
|
|
82
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
83
83
|
|
|
84
84
|
export default defineConfig({
|
|
85
85
|
resolve: {
|
|
86
86
|
alias: {
|
|
87
|
-
|
|
87
|
+
'@': './src',
|
|
88
88
|
},
|
|
89
89
|
// 'prefer-tsconfig' (default): tsconfig.json paths take priority
|
|
90
90
|
// 'prefer-alias': resolve.alias takes priority
|
|
91
|
-
aliasStrategy:
|
|
91
|
+
aliasStrategy: 'prefer-alias',
|
|
92
92
|
},
|
|
93
|
-
})
|
|
93
|
+
})
|
|
94
94
|
```
|
|
95
95
|
|
|
96
96
|
- Bump Rsbuild v1.5.4 with Rspack v1.5.2. ([#1644](https://github.com/lynx-family/lynx-stack/pull/1644))
|
|
@@ -110,7 +110,7 @@
|
|
|
110
110
|
- Add `output.dataUriLimit.*` for fine-grained control of asset inlining. ([#1648](https://github.com/lynx-family/lynx-stack/pull/1648))
|
|
111
111
|
|
|
112
112
|
```js
|
|
113
|
-
import { defineConfig } from
|
|
113
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
114
114
|
|
|
115
115
|
export default defineConfig({
|
|
116
116
|
output: {
|
|
@@ -119,7 +119,7 @@
|
|
|
119
119
|
media: 0,
|
|
120
120
|
},
|
|
121
121
|
},
|
|
122
|
-
})
|
|
122
|
+
})
|
|
123
123
|
```
|
|
124
124
|
|
|
125
125
|
## 0.11.0
|
|
@@ -239,28 +239,28 @@
|
|
|
239
239
|
|
|
240
240
|
```ts
|
|
241
241
|
type InlineChunkTestFunction = (params: {
|
|
242
|
-
size: number
|
|
243
|
-
name: string
|
|
244
|
-
}) => boolean
|
|
242
|
+
size: number
|
|
243
|
+
name: string
|
|
244
|
+
}) => boolean
|
|
245
245
|
|
|
246
|
-
type InlineChunkTest = RegExp | InlineChunkTestFunction
|
|
246
|
+
type InlineChunkTest = RegExp | InlineChunkTestFunction
|
|
247
247
|
|
|
248
248
|
type InlineChunkConfig =
|
|
249
249
|
| boolean
|
|
250
250
|
| InlineChunkTest
|
|
251
|
-
| { enable?: boolean |
|
|
251
|
+
| { enable?: boolean | 'auto', test: InlineChunkTest }
|
|
252
252
|
```
|
|
253
253
|
|
|
254
254
|
```ts
|
|
255
|
-
import { defineConfig } from
|
|
255
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
256
256
|
|
|
257
257
|
export default defineConfig({
|
|
258
258
|
output: {
|
|
259
259
|
inlineScripts: ({ name, size }) => {
|
|
260
|
-
return name.includes(
|
|
260
|
+
return name.includes('foo') && size < 1000
|
|
261
261
|
},
|
|
262
262
|
},
|
|
263
|
-
})
|
|
263
|
+
})
|
|
264
264
|
```
|
|
265
265
|
|
|
266
266
|
- docs: remove chunks: 'all' in comments ([#1168](https://github.com/lynx-family/lynx-stack/pull/1168))
|
|
@@ -303,13 +303,13 @@
|
|
|
303
303
|
example:
|
|
304
304
|
|
|
305
305
|
```js
|
|
306
|
-
import { defineConfig } from
|
|
306
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
307
307
|
|
|
308
308
|
export default defineConfig({
|
|
309
309
|
output: {
|
|
310
310
|
inlineScripts: false,
|
|
311
311
|
},
|
|
312
|
-
})
|
|
312
|
+
})
|
|
313
313
|
```
|
|
314
314
|
|
|
315
315
|
- Bump Rsbuild v1.3.21 with Rspack v1.3.11. ([#863](https://github.com/lynx-family/lynx-stack/pull/863))
|
|
@@ -329,12 +329,12 @@
|
|
|
329
329
|
example:
|
|
330
330
|
|
|
331
331
|
```js
|
|
332
|
-
import { defineConfig } from
|
|
332
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
333
333
|
export default defineConfig({
|
|
334
334
|
source: {
|
|
335
|
-
preEntry:
|
|
335
|
+
preEntry: './src/polyfill.ts',
|
|
336
336
|
},
|
|
337
|
-
})
|
|
337
|
+
})
|
|
338
338
|
```
|
|
339
339
|
|
|
340
340
|
- Bump Rsbuild v1.3.20 with Rspack v1.3.10. ([#799](https://github.com/lynx-family/lynx-stack/pull/799))
|
|
@@ -345,17 +345,17 @@
|
|
|
345
345
|
|
|
346
346
|
```js
|
|
347
347
|
export const myPlugin = {
|
|
348
|
-
name:
|
|
348
|
+
name: 'my-plugin',
|
|
349
349
|
setup(api) {
|
|
350
|
-
const { callerName } = api.context
|
|
350
|
+
const { callerName } = api.context
|
|
351
351
|
|
|
352
|
-
if (callerName ===
|
|
352
|
+
if (callerName === 'rslib') {
|
|
353
353
|
// ...
|
|
354
|
-
} else if (callerName ===
|
|
354
|
+
} else if (callerName === 'rspeedy') {
|
|
355
355
|
// ...
|
|
356
356
|
}
|
|
357
357
|
},
|
|
358
|
-
}
|
|
358
|
+
}
|
|
359
359
|
```
|
|
360
360
|
|
|
361
361
|
- Support `performance.buildCache`. ([#766](https://github.com/lynx-family/lynx-stack/pull/766))
|
|
@@ -378,7 +378,7 @@
|
|
|
378
378
|
Set `tools.rsdoctor.experiments.enableNativePlugin` to `false` to use the old JS plugin.
|
|
379
379
|
|
|
380
380
|
```js
|
|
381
|
-
import { defineConfig } from
|
|
381
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
382
382
|
|
|
383
383
|
export default defineConfig({
|
|
384
384
|
tools: {
|
|
@@ -388,7 +388,7 @@
|
|
|
388
388
|
},
|
|
389
389
|
},
|
|
390
390
|
},
|
|
391
|
-
})
|
|
391
|
+
})
|
|
392
392
|
```
|
|
393
393
|
|
|
394
394
|
See [Rsdoctor - 1.0](https://rsdoctor.dev/blog/release/release-note-1_0#-faster-analysis) for more details.
|
|
@@ -520,12 +520,12 @@
|
|
|
520
520
|
example:
|
|
521
521
|
|
|
522
522
|
```js
|
|
523
|
-
import { defineConfig } from
|
|
523
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
524
524
|
export default defineConfig({
|
|
525
525
|
server: {
|
|
526
|
-
base:
|
|
526
|
+
base: '/dist',
|
|
527
527
|
},
|
|
528
|
-
})
|
|
528
|
+
})
|
|
529
529
|
```
|
|
530
530
|
|
|
531
531
|
- Updated dependencies [[`b026c8b`](https://github.com/lynx-family/lynx-stack/commit/b026c8bdcbf7bdcda73e170477297213b447d876)]:
|
|
@@ -578,11 +578,11 @@
|
|
|
578
578
|
You can switch to other tools by using:
|
|
579
579
|
|
|
580
580
|
```js
|
|
581
|
-
import { defineConfig } from
|
|
581
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
582
582
|
import {
|
|
583
583
|
CssMinimizerWebpackPlugin,
|
|
584
584
|
pluginCssMinimizer,
|
|
585
|
-
} from
|
|
585
|
+
} from '@rsbuild/plugin-css-minimizer'
|
|
586
586
|
|
|
587
587
|
export default defineConfig({
|
|
588
588
|
plugins: [
|
|
@@ -595,7 +595,7 @@
|
|
|
595
595
|
},
|
|
596
596
|
}),
|
|
597
597
|
],
|
|
598
|
-
})
|
|
598
|
+
})
|
|
599
599
|
```
|
|
600
600
|
|
|
601
601
|
See [@rsbuild/plugin-css-minimizer](https://github.com/rspack-contrib/rsbuild-plugin-css-minimizer) for details.
|
|
@@ -605,8 +605,8 @@
|
|
|
605
605
|
You can use custom options with [@rsbuild/plugin-css-minimizer](https://github.com/rspack-contrib/rsbuild-plugin-css-minimizer):
|
|
606
606
|
|
|
607
607
|
```js
|
|
608
|
-
import { defineConfig } from
|
|
609
|
-
import { pluginCssMinimizer } from
|
|
608
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
609
|
+
import { pluginCssMinimizer } from '@rsbuild/plugin-css-minimizer'
|
|
610
610
|
|
|
611
611
|
export default defineConfig({
|
|
612
612
|
plugins: [
|
|
@@ -618,7 +618,7 @@
|
|
|
618
618
|
},
|
|
619
619
|
}),
|
|
620
620
|
],
|
|
621
|
-
})
|
|
621
|
+
})
|
|
622
622
|
```
|
|
623
623
|
|
|
624
624
|
## 0.7.1
|
|
@@ -638,7 +638,7 @@
|
|
|
638
638
|
You may turn it off using `output.minify.css: false`:
|
|
639
639
|
|
|
640
640
|
```js
|
|
641
|
-
import { defineConfig } from
|
|
641
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
642
642
|
|
|
643
643
|
export default defineConfig({
|
|
644
644
|
output: {
|
|
@@ -646,18 +646,18 @@
|
|
|
646
646
|
css: false,
|
|
647
647
|
},
|
|
648
648
|
},
|
|
649
|
-
})
|
|
649
|
+
})
|
|
650
650
|
```
|
|
651
651
|
|
|
652
652
|
Or you may use [@rsbuild/plugin-css-minimizer](https://github.com/rspack-contrib/rsbuild-plugin-css-minimizer) to use `cssnano` as CSS minimizer.
|
|
653
653
|
|
|
654
654
|
```js
|
|
655
|
-
import { defineConfig } from
|
|
656
|
-
import { pluginCssMinimizer } from
|
|
655
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
656
|
+
import { pluginCssMinimizer } from '@rsbuild/plugin-css-minimizer'
|
|
657
657
|
|
|
658
658
|
export default defineConfig({
|
|
659
659
|
plugins: [pluginCssMinimizer()],
|
|
660
|
-
})
|
|
660
|
+
})
|
|
661
661
|
```
|
|
662
662
|
|
|
663
663
|
- 525554c: **BREAKING CHANGE**: Bump ts-blank-space to ^0.6.0.
|
|
@@ -684,22 +684,22 @@
|
|
|
684
684
|
- The new `type: 'reload-server'` will restart the development server when it detects changes in the specified files.
|
|
685
685
|
|
|
686
686
|
```js
|
|
687
|
-
import { defineConfig } from
|
|
687
|
+
import { defineConfig } from '@lynx-js/rspeedy'
|
|
688
688
|
|
|
689
689
|
export default defineConfig({
|
|
690
690
|
dev: {
|
|
691
691
|
watchFiles: [
|
|
692
692
|
{
|
|
693
|
-
type:
|
|
694
|
-
paths: [
|
|
693
|
+
type: 'reload-server',
|
|
694
|
+
paths: ['public/**/*.txt'],
|
|
695
695
|
},
|
|
696
696
|
{
|
|
697
|
-
type:
|
|
698
|
-
paths: [
|
|
697
|
+
type: 'reload-page',
|
|
698
|
+
paths: ['public/**/*.json'],
|
|
699
699
|
},
|
|
700
700
|
],
|
|
701
701
|
},
|
|
702
|
-
})
|
|
702
|
+
})
|
|
703
703
|
```
|
|
704
704
|
|
|
705
705
|
- be9b003: Add `source.exclude`.
|
|
@@ -63,7 +63,7 @@ export const __webpack_modules__ = {
|
|
|
63
63
|
});
|
|
64
64
|
var core_ = __webpack_require__("@rsbuild/core");
|
|
65
65
|
var package_namespaceObject = {
|
|
66
|
-
rE: "0.11.
|
|
66
|
+
rE: "0.11.6"
|
|
67
67
|
};
|
|
68
68
|
const version = package_namespaceObject.rE;
|
|
69
69
|
const rspackVersion = core_.rspack.rspackVersion;
|
package/dist/1~src_version_ts.js
CHANGED
|
@@ -11,7 +11,7 @@ export const __webpack_modules__ = {
|
|
|
11
11
|
});
|
|
12
12
|
var core_ = __webpack_require__("@rsbuild/core");
|
|
13
13
|
var package_namespaceObject = {
|
|
14
|
-
rE: "0.11.
|
|
14
|
+
rE: "0.11.6"
|
|
15
15
|
};
|
|
16
16
|
const version = package_namespaceObject.rE;
|
|
17
17
|
const rspackVersion = core_.rspack.rspackVersion;
|
package/dist/index.js
CHANGED
|
@@ -108,7 +108,7 @@ var __webpack_modules__ = {
|
|
|
108
108
|
});
|
|
109
109
|
var core_ = __webpack_require__("@rsbuild/core");
|
|
110
110
|
var package_namespaceObject = {
|
|
111
|
-
rE: "0.11.
|
|
111
|
+
rE: "0.11.6"
|
|
112
112
|
};
|
|
113
113
|
const version = package_namespaceObject.rE;
|
|
114
114
|
const rspackVersion = core_.rspack.rspackVersion;
|