@rsbuild/core 2.0.7 → 2.0.8
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/compiled/css-loader/index.js +2 -2
- package/compiled/html-rspack-plugin/index.js +14 -14
- package/compiled/postcss/index.js +1 -1
- package/compiled/postcss/package.json +1 -1
- package/compiled/postcss-loader/index.js +6 -6
- package/dist/{753.js → 756.js} +148 -125
- package/dist/client/hmr.js +1 -1
- package/dist/client/overlay.js +1 -1
- package/dist/http-proxy-middleware.js +2 -5
- package/dist/index.js +1 -1
- package/dist/launch-editor-middleware.js +1 -1
- package/dist/manifest-plugin.js +7 -7
- package/dist/memfs.js +1 -1
- package/dist/ws.js +45 -31
- package/dist-types/helpers/packageJson.d.ts +1 -1
- package/dist-types/index.d.ts +1 -1
- package/dist-types/plugins/css.d.ts +1 -1
- package/dist-types/plugins/externals.d.ts +1 -1
- package/dist-types/server/helper.d.ts +3 -2
- package/dist-types/types/config.d.ts +20 -7
- package/package.json +8 -8
- /package/dist/{753.js.LICENSE.txt → 756.js.LICENSE.txt} +0 -0
- /package/dist/client/{797.js → 60.js} +0 -0
|
@@ -10,7 +10,7 @@ import { URL as external_url_URL } from "url";
|
|
|
10
10
|
import "node:zlib";
|
|
11
11
|
import "node:querystring";
|
|
12
12
|
import { __webpack_require__ } from "./1~rslib-runtime.js";
|
|
13
|
-
import "./
|
|
13
|
+
import "./756.js";
|
|
14
14
|
__webpack_require__.add({
|
|
15
15
|
"../../node_modules/.pnpm/braces@3.0.3/node_modules/braces/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
16
16
|
let stringify = __webpack_require__("../../node_modules/.pnpm/braces@3.0.3/node_modules/braces/lib/stringify.js"), compile = __webpack_require__("../../node_modules/.pnpm/braces@3.0.3/node_modules/braces/lib/compile.js"), expand = __webpack_require__("../../node_modules/.pnpm/braces@3.0.3/node_modules/braces/lib/expand.js"), parse = __webpack_require__("../../node_modules/.pnpm/braces@3.0.3/node_modules/braces/lib/parse.js"), braces = (input, options = {})=>{
|
|
@@ -592,10 +592,7 @@ __webpack_require__.add({
|
|
|
592
592
|
1
|
|
593
593
|
];
|
|
594
594
|
try {
|
|
595
|
-
let supportsColor = __webpack_require__(
|
|
596
|
-
var e = Error("Cannot find module 'supports-color'");
|
|
597
|
-
throw e.code = 'MODULE_NOT_FOUND', e;
|
|
598
|
-
}()));
|
|
595
|
+
let supportsColor = __webpack_require__("supports-color");
|
|
599
596
|
supportsColor && (supportsColor.stderr || supportsColor).level >= 2 && (exports.colors = [
|
|
600
597
|
20,
|
|
601
598
|
21,
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { PLUGIN_CSS_NAME, PLUGIN_SWC_NAME, createLogger, createRsbuild, defaultAllowedOrigins, defineConfig, ensureAssetPrefix, loadConfig, loadEnv, logger, mergeRsbuildConfig, rspack, runCLI, version } from "./
|
|
1
|
+
export { PLUGIN_CSS_NAME, PLUGIN_SWC_NAME, createLogger, createRsbuild, defaultAllowedOrigins, defineConfig, ensureAssetPrefix, loadConfig, loadEnv, logger, mergeRsbuildConfig, rspack, runCLI, version } from "./756.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __webpack_require__ } from "./1~rslib-runtime.js";
|
|
2
|
-
import "./
|
|
2
|
+
import "./756.js";
|
|
3
3
|
__webpack_require__.add({
|
|
4
4
|
"../../node_modules/.pnpm/launch-editor-middleware@2.13.2/node_modules/launch-editor-middleware/index.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
5
5
|
let path = __webpack_require__("path?aeb1"), launch = __webpack_require__("../../node_modules/.pnpm/launch-editor@2.13.2/node_modules/launch-editor/index.js");
|
package/dist/manifest-plugin.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { __webpack_require__ } from "./1~rslib-runtime.js";
|
|
2
|
-
import "./
|
|
2
|
+
import "./756.js";
|
|
3
3
|
__webpack_require__.add({
|
|
4
|
-
"../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.
|
|
4
|
+
"../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.5/node_modules/rspack-manifest-plugin/dist/helpers.js" (__unused_rspack_module, exports, __webpack_require__) {
|
|
5
5
|
exports.transformFiles = exports.reduceChunk = exports.reduceAssets = exports.generateManifest = void 0;
|
|
6
6
|
let node_path_1 = __webpack_require__("node:path?435f");
|
|
7
7
|
exports.generateManifest = (compilation, files, { generate, seed = {} })=>generate ? generate(seed, files, Array.from(compilation.entrypoints.entries()).reduce((e, [name, entrypoint])=>Object.assign(e, {
|
|
@@ -61,9 +61,9 @@ __webpack_require__.add({
|
|
|
61
61
|
'sort'
|
|
62
62
|
].filter((fname)=>!!options[fname]).reduce((prev, fname)=>prev[fname](options[fname]), files).map(standardizeFilePaths);
|
|
63
63
|
},
|
|
64
|
-
"../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.
|
|
64
|
+
"../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.5/node_modules/rspack-manifest-plugin/dist/hooks.js" (__unused_rspack_module, exports, __webpack_require__) {
|
|
65
65
|
exports.getCompilerHooks = exports.emitHook = exports.beforeRunHook = void 0;
|
|
66
|
-
let node_fs_1 = __webpack_require__("node:fs?9592"), node_path_1 = __webpack_require__("node:path?435f"), lite_tapable_1 = __webpack_require__("../../node_modules/.pnpm/@rspack+lite-tapable@1.1.0/node_modules/@rspack/lite-tapable/dist/index.cjs"), helpers_1 = __webpack_require__("../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.
|
|
66
|
+
let node_fs_1 = __webpack_require__("node:fs?9592"), node_path_1 = __webpack_require__("node:path?435f"), lite_tapable_1 = __webpack_require__("../../node_modules/.pnpm/@rspack+lite-tapable@1.1.0/node_modules/@rspack/lite-tapable/dist/index.cjs"), helpers_1 = __webpack_require__("../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.5/node_modules/rspack-manifest-plugin/dist/helpers.js"), compilerHookMap = new WeakMap(), getCompilerHooks = (compiler)=>{
|
|
67
67
|
let hooks = compilerHookMap.get(compiler);
|
|
68
68
|
return void 0 === hooks && (hooks = {
|
|
69
69
|
afterEmit: new lite_tapable_1.SyncWaterfallHook([
|
|
@@ -112,9 +112,9 @@ __webpack_require__.add({
|
|
|
112
112
|
getCompilerHooks(compiler).afterEmit.call(manifest);
|
|
113
113
|
};
|
|
114
114
|
},
|
|
115
|
-
"../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.
|
|
115
|
+
"../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.5/node_modules/rspack-manifest-plugin/dist/index.js" (__unused_rspack_module, exports, __webpack_require__) {
|
|
116
116
|
exports.RspackManifestPlugin = void 0;
|
|
117
|
-
let node_path_1 = __webpack_require__("node:path?435f"), hooks_1 = __webpack_require__("../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.
|
|
117
|
+
let node_path_1 = __webpack_require__("node:path?435f"), hooks_1 = __webpack_require__("../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.5/node_modules/rspack-manifest-plugin/dist/hooks.js"), emitCountMap = new Map(), defaults = {
|
|
118
118
|
assetHookStage: 1 / 0,
|
|
119
119
|
basePath: '',
|
|
120
120
|
fileName: 'manifest.json',
|
|
@@ -683,5 +683,5 @@ __webpack_require__.add({
|
|
|
683
683
|
});
|
|
684
684
|
}
|
|
685
685
|
});
|
|
686
|
-
var RspackManifestPlugin = __webpack_require__("../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.
|
|
686
|
+
var RspackManifestPlugin = __webpack_require__("../../node_modules/.pnpm/rspack-manifest-plugin@5.2.1_@rspack+core@2.0.5/node_modules/rspack-manifest-plugin/dist/index.js").RspackManifestPlugin;
|
|
687
687
|
export { RspackManifestPlugin };
|
package/dist/memfs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __webpack_require__ } from "./1~rslib-runtime.js";
|
|
2
|
-
import "./
|
|
2
|
+
import "./756.js";
|
|
3
3
|
__webpack_require__.add({
|
|
4
4
|
"../../node_modules/.pnpm/@jsonjoy.com+base64@17.67.0_tslib@2.8.1/node_modules/@jsonjoy.com/base64/lib/constants.js" (__unused_rspack_module, exports) {
|
|
5
5
|
exports.alphabet = void 0, exports.alphabet = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/', 'function' == typeof Buffer && Buffer.from;
|
package/dist/ws.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { __webpack_require__ } from "./1~rslib-runtime.js";
|
|
2
|
-
import "./
|
|
2
|
+
import "./756.js";
|
|
3
3
|
__webpack_require__.add({
|
|
4
|
-
"../../node_modules/.pnpm/ws@8.
|
|
5
|
-
let { EMPTY_BUFFER } = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
4
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/buffer-util.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
5
|
+
let { EMPTY_BUFFER } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js"), FastBuffer = Buffer[Symbol.species];
|
|
6
6
|
function toBuffer(data) {
|
|
7
7
|
let buf;
|
|
8
8
|
return (toBuffer.readOnly = !0, Buffer.isBuffer(data)) ? data : (data instanceof ArrayBuffer ? buf = new FastBuffer(data) : ArrayBuffer.isView(data) ? buf = new FastBuffer(data.buffer, data.byteOffset, data.byteLength) : (buf = Buffer.from(data), toBuffer.readOnly = !1), buf);
|
|
@@ -30,7 +30,7 @@ __webpack_require__.add({
|
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
32
|
},
|
|
33
|
-
"../../node_modules/.pnpm/ws@8.
|
|
33
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js" (module) {
|
|
34
34
|
let BINARY_TYPES = [
|
|
35
35
|
'nodebuffer',
|
|
36
36
|
'arraybuffer',
|
|
@@ -49,8 +49,8 @@ __webpack_require__.add({
|
|
|
49
49
|
NOOP: ()=>{}
|
|
50
50
|
};
|
|
51
51
|
},
|
|
52
|
-
"../../node_modules/.pnpm/ws@8.
|
|
53
|
-
let { kForOnEventAttribute, kListener } = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
52
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/event-target.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
53
|
+
let { kForOnEventAttribute, kListener } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js"), kCode = Symbol('kCode'), kData = Symbol('kData'), kError = Symbol('kError'), kMessage = Symbol('kMessage'), kReason = Symbol('kReason'), kTarget = Symbol('kTarget'), kType = Symbol('kType'), kWasClean = Symbol('kWasClean');
|
|
54
54
|
class Event {
|
|
55
55
|
constructor(type){
|
|
56
56
|
this[kTarget] = null, this[kType] = type;
|
|
@@ -165,8 +165,8 @@ __webpack_require__.add({
|
|
|
165
165
|
MessageEvent
|
|
166
166
|
};
|
|
167
167
|
},
|
|
168
|
-
"../../node_modules/.pnpm/ws@8.
|
|
169
|
-
let { tokenChars } = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
168
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/extension.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
169
|
+
let { tokenChars } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/validation.js");
|
|
170
170
|
function push(dest, name, elem) {
|
|
171
171
|
void 0 === dest[name] ? dest[name] = [
|
|
172
172
|
elem
|
|
@@ -228,7 +228,7 @@ __webpack_require__.add({
|
|
|
228
228
|
}
|
|
229
229
|
};
|
|
230
230
|
},
|
|
231
|
-
"../../node_modules/.pnpm/ws@8.
|
|
231
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/limiter.js" (module) {
|
|
232
232
|
let kDone = Symbol('kDone'), kRun = Symbol('kRun');
|
|
233
233
|
module.exports = class {
|
|
234
234
|
constructor(concurrency){
|
|
@@ -247,8 +247,8 @@ __webpack_require__.add({
|
|
|
247
247
|
}
|
|
248
248
|
};
|
|
249
249
|
},
|
|
250
|
-
"../../node_modules/.pnpm/ws@8.
|
|
251
|
-
let zlibLimiter, zlib = __webpack_require__("zlib"), bufferUtil = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
250
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/permessage-deflate.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
251
|
+
let zlibLimiter, zlib = __webpack_require__("zlib"), bufferUtil = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/buffer-util.js"), Limiter = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/limiter.js"), { kStatusCode } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js"), FastBuffer = Buffer[Symbol.species], TRAILER = Buffer.from([
|
|
252
252
|
0x00,
|
|
253
253
|
0x00,
|
|
254
254
|
0xff,
|
|
@@ -368,15 +368,14 @@ __webpack_require__.add({
|
|
|
368
368
|
}
|
|
369
369
|
};
|
|
370
370
|
},
|
|
371
|
-
"../../node_modules/.pnpm/ws@8.
|
|
372
|
-
let { Writable } = __webpack_require__("stream"), PerMessageDeflate = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
371
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/receiver.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
372
|
+
let { Writable } = __webpack_require__("stream"), PerMessageDeflate = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/permessage-deflate.js"), { BINARY_TYPES, EMPTY_BUFFER, kStatusCode, kWebSocket } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js"), { concat, toArrayBuffer, unmask } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/buffer-util.js"), { isValidStatusCode, isValidUTF8 } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/validation.js"), FastBuffer = Buffer[Symbol.species];
|
|
373
373
|
module.exports = class extends Writable {
|
|
374
374
|
constructor(options = {}){
|
|
375
|
-
super(), this._allowSynchronousEvents = void 0 === options.allowSynchronousEvents || options.allowSynchronousEvents, this._binaryType = options.binaryType || BINARY_TYPES[0], this._extensions = options.extensions || {}, this._isServer = !!options.isServer, this._maxPayload = 0 | options.maxPayload, this._skipUTF8Validation = !!options.skipUTF8Validation, this[kWebSocket] = void 0, this._bufferedBytes = 0, this._buffers = [], this._compressed = !1, this._payloadLength = 0, this._mask = void 0, this._fragmented = 0, this._masked = !1, this._fin = !1, this._opcode = 0, this._totalPayloadLength = 0, this._messageLength = 0, this._fragments = [], this._errored = !1, this._loop = !1, this._state = 0;
|
|
375
|
+
super(), this._allowSynchronousEvents = void 0 === options.allowSynchronousEvents || options.allowSynchronousEvents, this._binaryType = options.binaryType || BINARY_TYPES[0], this._extensions = options.extensions || {}, this._isServer = !!options.isServer, this._maxBufferedChunks = 0 | options.maxBufferedChunks, this._maxFragments = 0 | options.maxFragments, this._maxPayload = 0 | options.maxPayload, this._skipUTF8Validation = !!options.skipUTF8Validation, this[kWebSocket] = void 0, this._bufferedBytes = 0, this._buffers = [], this._compressed = !1, this._payloadLength = 0, this._mask = void 0, this._fragmented = 0, this._masked = !1, this._fin = !1, this._opcode = 0, this._totalPayloadLength = 0, this._messageLength = 0, this._fragments = [], this._errored = !1, this._loop = !1, this._state = 0;
|
|
376
376
|
}
|
|
377
377
|
_write(chunk, encoding, cb) {
|
|
378
|
-
|
|
379
|
-
this._bufferedBytes += chunk.length, this._buffers.push(chunk), this.startLoop(cb);
|
|
378
|
+
return 0x08 === this._opcode && 0 == this._state ? cb() : this._maxBufferedChunks > 0 && this._buffers.length >= this._maxBufferedChunks ? void cb(this.createError(RangeError, 'Too many buffered chunks', !1, 1008, 'WS_ERR_TOO_MANY_BUFFERED_PARTS')) : void (this._bufferedBytes += chunk.length, this._buffers.push(chunk), this.startLoop(cb));
|
|
380
379
|
}
|
|
381
380
|
consume(n) {
|
|
382
381
|
if (this._bufferedBytes -= n, n === this._buffers[0].length) return this._buffers.shift();
|
|
@@ -483,13 +482,18 @@ __webpack_require__.add({
|
|
|
483
482
|
this._state = 5, this.decompress(data, cb);
|
|
484
483
|
return;
|
|
485
484
|
}
|
|
486
|
-
data.length
|
|
485
|
+
if (data.length) {
|
|
486
|
+
if (this._maxFragments > 0 && this._fragments.length >= this._maxFragments) return void cb(this.createError(RangeError, 'Too many message fragments', !1, 1008, 'WS_ERR_TOO_MANY_BUFFERED_PARTS'));
|
|
487
|
+
this._messageLength = this._totalPayloadLength, this._fragments.push(data);
|
|
488
|
+
}
|
|
489
|
+
this.dataMessage(cb);
|
|
487
490
|
}
|
|
488
491
|
decompress(data, cb) {
|
|
489
492
|
this._extensions[PerMessageDeflate.extensionName].decompress(data, this._fin, (err, buf)=>{
|
|
490
493
|
if (err) return cb(err);
|
|
491
494
|
if (buf.length) {
|
|
492
495
|
if (this._messageLength += buf.length, this._messageLength > this._maxPayload && this._maxPayload > 0) return void cb(this.createError(RangeError, 'Max payload size exceeded', !1, 1009, 'WS_ERR_UNSUPPORTED_MESSAGE_LENGTH'));
|
|
496
|
+
if (this._maxFragments > 0 && this._fragments.length >= this._maxFragments) return void cb(this.createError(RangeError, 'Too many message fragments', !1, 1008, 'WS_ERR_TOO_MANY_BUFFERED_PARTS'));
|
|
493
497
|
this._fragments.push(buf);
|
|
494
498
|
}
|
|
495
499
|
this.dataMessage(cb), 0 === this._state && this.startLoop(cb);
|
|
@@ -538,8 +542,8 @@ __webpack_require__.add({
|
|
|
538
542
|
}
|
|
539
543
|
};
|
|
540
544
|
},
|
|
541
|
-
"../../node_modules/.pnpm/ws@8.
|
|
542
|
-
let randomPool, { Duplex } = __webpack_require__("stream"), { randomFillSync } = __webpack_require__("crypto"), { types: { isUint8Array } } = __webpack_require__("util"), PerMessageDeflate = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
545
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/sender.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
546
|
+
let randomPool, { Duplex } = __webpack_require__("stream"), { randomFillSync } = __webpack_require__("crypto"), { types: { isUint8Array } } = __webpack_require__("util"), PerMessageDeflate = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/permessage-deflate.js"), { EMPTY_BUFFER, kWebSocket, NOOP } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js"), { isBlob, isValidStatusCode } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/validation.js"), { mask: applyMask, toBuffer } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/buffer-util.js"), kByteLength = Symbol('kByteLength'), maskBuffer = Buffer.alloc(4), randomPoolPointer = 8192;
|
|
543
547
|
function callCallbacks(sender, err, cb) {
|
|
544
548
|
'function' == typeof cb && cb(err);
|
|
545
549
|
for(let i = 0; i < sender._queue.length; i++){
|
|
@@ -718,8 +722,8 @@ __webpack_require__.add({
|
|
|
718
722
|
}
|
|
719
723
|
};
|
|
720
724
|
},
|
|
721
|
-
"../../node_modules/.pnpm/ws@8.
|
|
722
|
-
__webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
725
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/stream.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
726
|
+
__webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/websocket.js");
|
|
723
727
|
let { Duplex } = __webpack_require__("stream");
|
|
724
728
|
function emitClose(stream) {
|
|
725
729
|
stream.emit('close');
|
|
@@ -771,8 +775,8 @@ __webpack_require__.add({
|
|
|
771
775
|
}, duplex.on('end', duplexOnEnd), duplex.on('error', duplexOnError), duplex;
|
|
772
776
|
};
|
|
773
777
|
},
|
|
774
|
-
"../../node_modules/.pnpm/ws@8.
|
|
775
|
-
let { tokenChars } = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
778
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/subprotocol.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
779
|
+
let { tokenChars } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/validation.js");
|
|
776
780
|
module.exports = {
|
|
777
781
|
parse: function parse(header) {
|
|
778
782
|
let protocols = new Set(), start = -1, end = -1, i = 0;
|
|
@@ -795,8 +799,8 @@ __webpack_require__.add({
|
|
|
795
799
|
}
|
|
796
800
|
};
|
|
797
801
|
},
|
|
798
|
-
"../../node_modules/.pnpm/ws@8.
|
|
799
|
-
let { isUtf8 } = __webpack_require__("buffer"), { hasBlob } = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
802
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/validation.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
803
|
+
let { isUtf8 } = __webpack_require__("buffer"), { hasBlob } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js");
|
|
800
804
|
function _isValidUTF8(buf) {
|
|
801
805
|
let len = buf.length, i = 0;
|
|
802
806
|
for(; i < len;)if ((0x80 & buf[i]) == 0) i++;
|
|
@@ -954,8 +958,8 @@ __webpack_require__.add({
|
|
|
954
958
|
return buf.length < 24 ? _isValidUTF8(buf) : isUtf8(buf);
|
|
955
959
|
});
|
|
956
960
|
},
|
|
957
|
-
"../../node_modules/.pnpm/ws@8.
|
|
958
|
-
let EventEmitter = __webpack_require__("events"), http = __webpack_require__("http"), { Duplex } = __webpack_require__("stream"), { createHash } = __webpack_require__("crypto"), extension = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
961
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/websocket-server.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
962
|
+
let EventEmitter = __webpack_require__("events"), http = __webpack_require__("http"), { Duplex } = __webpack_require__("stream"), { createHash } = __webpack_require__("crypto"), extension = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/extension.js"), PerMessageDeflate = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/permessage-deflate.js"), subprotocol = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/subprotocol.js"), WebSocket = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/websocket.js"), { CLOSE_TIMEOUT, GUID, kWebSocket } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js"), keyRegex = /^[+/0-9A-Za-z]{22}==$/;
|
|
959
963
|
function addListeners(server, map) {
|
|
960
964
|
for (let event of Object.keys(map))server.on(event, map[event]);
|
|
961
965
|
return function removeListeners() {
|
|
@@ -987,6 +991,8 @@ __webpack_require__.add({
|
|
|
987
991
|
if (super(), null == (options = {
|
|
988
992
|
allowSynchronousEvents: !0,
|
|
989
993
|
autoPong: !0,
|
|
994
|
+
maxBufferedChunks: 1048576,
|
|
995
|
+
maxFragments: 131072,
|
|
990
996
|
maxPayload: 104857600,
|
|
991
997
|
skipUTF8Validation: !1,
|
|
992
998
|
perMessageDeflate: !1,
|
|
@@ -1117,6 +1123,8 @@ __webpack_require__.add({
|
|
|
1117
1123
|
}
|
|
1118
1124
|
this.emit('headers', headers, req), socket.write(headers.concat('\r\n').join('\r\n')), socket.removeListener('error', socketOnError), ws.setSocket(socket, head, {
|
|
1119
1125
|
allowSynchronousEvents: this.options.allowSynchronousEvents,
|
|
1126
|
+
maxBufferedChunks: this.options.maxBufferedChunks,
|
|
1127
|
+
maxFragments: this.options.maxFragments,
|
|
1120
1128
|
maxPayload: this.options.maxPayload,
|
|
1121
1129
|
skipUTF8Validation: this.options.skipUTF8Validation
|
|
1122
1130
|
}), this.clients && (this.clients.add(ws), ws.on('close', ()=>{
|
|
@@ -1125,8 +1133,8 @@ __webpack_require__.add({
|
|
|
1125
1133
|
}
|
|
1126
1134
|
};
|
|
1127
1135
|
},
|
|
1128
|
-
"../../node_modules/.pnpm/ws@8.
|
|
1129
|
-
let EventEmitter = __webpack_require__("events"), https = __webpack_require__("https"), http = __webpack_require__("http"), net = __webpack_require__("net"), tls = __webpack_require__("tls"), { randomBytes, createHash } = __webpack_require__("crypto"), { Duplex, Readable } = __webpack_require__("stream"), { URL } = __webpack_require__("url?b918"), PerMessageDeflate = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
1136
|
+
"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/websocket.js" (module, __unused_rspack_exports, __webpack_require__) {
|
|
1137
|
+
let EventEmitter = __webpack_require__("events"), https = __webpack_require__("https"), http = __webpack_require__("http"), net = __webpack_require__("net"), tls = __webpack_require__("tls"), { randomBytes, createHash } = __webpack_require__("crypto"), { Duplex, Readable } = __webpack_require__("stream"), { URL } = __webpack_require__("url?b918"), PerMessageDeflate = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/permessage-deflate.js"), Receiver = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/receiver.js"), Sender = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/sender.js"), { isBlob } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/validation.js"), { BINARY_TYPES, CLOSE_TIMEOUT, EMPTY_BUFFER, GUID, kForOnEventAttribute, kListener, kStatusCode, kWebSocket, NOOP } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js"), { EventTarget: { addEventListener, removeEventListener } } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/event-target.js"), { format, parse } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/extension.js"), { toBuffer } = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/buffer-util.js"), kAborted = Symbol('kAborted'), protocolVersions = [
|
|
1130
1138
|
8,
|
|
1131
1139
|
13
|
|
1132
1140
|
], readyStates = [
|
|
@@ -1183,6 +1191,8 @@ __webpack_require__.add({
|
|
|
1183
1191
|
binaryType: this.binaryType,
|
|
1184
1192
|
extensions: this._extensions,
|
|
1185
1193
|
isServer: this._isServer,
|
|
1194
|
+
maxBufferedChunks: options.maxBufferedChunks,
|
|
1195
|
+
maxFragments: options.maxFragments,
|
|
1186
1196
|
maxPayload: options.maxPayload,
|
|
1187
1197
|
skipUTF8Validation: options.skipUTF8Validation
|
|
1188
1198
|
}), sender = new Sender(socket, this._extensions, options.generateMask);
|
|
@@ -1246,6 +1256,8 @@ __webpack_require__.add({
|
|
|
1246
1256
|
autoPong: !0,
|
|
1247
1257
|
closeTimeout: CLOSE_TIMEOUT,
|
|
1248
1258
|
protocolVersion: protocolVersions[1],
|
|
1259
|
+
maxBufferedChunks: 1048576,
|
|
1260
|
+
maxFragments: 131072,
|
|
1249
1261
|
maxPayload: 104857600,
|
|
1250
1262
|
skipUTF8Validation: !1,
|
|
1251
1263
|
perMessageDeflate: !0,
|
|
@@ -1365,6 +1377,8 @@ __webpack_require__.add({
|
|
|
1365
1377
|
websocket.setSocket(socket, head, {
|
|
1366
1378
|
allowSynchronousEvents: opts.allowSynchronousEvents,
|
|
1367
1379
|
generateMask: opts.generateMask,
|
|
1380
|
+
maxBufferedChunks: opts.maxBufferedChunks,
|
|
1381
|
+
maxFragments: opts.maxFragments,
|
|
1368
1382
|
maxPayload: opts.maxPayload,
|
|
1369
1383
|
skipUTF8Validation: opts.skipUTF8Validation
|
|
1370
1384
|
});
|
|
@@ -1509,6 +1523,6 @@ __webpack_require__.add({
|
|
|
1509
1523
|
}), WebSocket.prototype.addEventListener = addEventListener, WebSocket.prototype.removeEventListener = removeEventListener, module.exports = WebSocket;
|
|
1510
1524
|
}
|
|
1511
1525
|
});
|
|
1512
|
-
let websocket_server = __webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
1513
|
-
__webpack_require__("../../node_modules/.pnpm/ws@8.
|
|
1526
|
+
let websocket_server = __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/websocket-server.js");
|
|
1527
|
+
__webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/stream.js"), __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/extension.js"), __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/permessage-deflate.js"), __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/receiver.js"), __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/sender.js"), __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/subprotocol.js"), __webpack_require__("../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/websocket.js");
|
|
1514
1528
|
export { websocket_server as WebSocketServer };
|
|
@@ -6,4 +6,4 @@ export type PackageJson = Partial<{
|
|
|
6
6
|
peerDependencies: Record<string, string>;
|
|
7
7
|
devDependencies: Record<string, string>;
|
|
8
8
|
}>;
|
|
9
|
-
export declare const
|
|
9
|
+
export declare const readPackageJsonByPath: (pkgJsonPath: string) => Promise<PackageJson | undefined>;
|
package/dist-types/index.d.ts
CHANGED
|
@@ -20,4 +20,4 @@ export { mergeRsbuildConfig } from './mergeConfig';
|
|
|
20
20
|
export type { RsbuildDevServer } from './server/devServer';
|
|
21
21
|
export type { RsbuildServerBase, ServerStartResult, StartDevServerResult, StartPreviewServerResult, } from './server/helper';
|
|
22
22
|
export type { RsbuildPreviewServer } from './server/previewServer';
|
|
23
|
-
export type { AliasStrategy, AppIcon, AppIconItem, AutoExternal, Build, BuildOptions, BuildResult, Charset, CleanDistPath, CleanDistPathObject, ClientConfig, CliShortcut, CompressOptions, ConfigChain, ConfigChainWithContext, Connect, ConsoleType, CreateCompiler, CreateRsbuildOptions, CrossOrigin, CSSLoaderOptions, CSSModules, CSSModulesLocalsConvention, DataUriLimit, Decorators, DevConfig, DistPathConfig, EnvironmentConfig, EnvironmentContext, FilenameConfig, FilenameHash, HistoryApiFallbackContext, HistoryApiFallbackOptions, HtmlBasicTag, HtmlConfig, HtmlFallback, HtmlRspackPlugin, HtmlTag, HtmlTagContext, HtmlTagDescriptor, HtmlTagHandler, InitConfigsOptions, InlineChunkConfig, InlineChunkTest, InlineChunkTestFunction, InspectConfigOptions, InspectConfigResult, InternalContext, LegalComments, LogLevel, ManifestConfig, ManifestData, ManifestObjectConfig, MergedEnvironmentConfig, MetaAttrs, MetaOptions, Minify, ModifyBundlerChainFn, ModifyBundlerChainUtils, ModifyChainUtils, ModifyEnvironmentConfigFn, ModifyEnvironmentConfigUtils, ModifyHTMLContext, ModifyHTMLFn, ModifyHTMLTagsContext, ModifyHTMLTagsFn, ModifyRsbuildConfigFn, ModifyRsbuildConfigUtils, ModifyRspackConfigFn, ModifyRspackConfigUtils, ModuleFederationConfig, NormalizedConfig, NormalizedDevConfig, NormalizedEnvironmentConfig, NormalizedHtmlConfig, NormalizedModuleFederationConfig, NormalizedOutputConfig, NormalizedPerformanceConfig, NormalizedResolveConfig, NormalizedSecurityConfig, NormalizedServerConfig, NormalizedSourceConfig, NormalizedSplitChunksConfig, NormalizedToolsConfig, OnAfterBuildFn, OnAfterCreateCompilerFn, OnAfterDevCompileFn, OnAfterEnvironmentCompileFn, OnAfterStartDevServerFn, OnAfterStartPreviewServerFn, OnBeforeBuildFn, OnBeforeCreateCompilerFn, OnBeforeDevCompileFn, OnBeforeEnvironmentCompileFn, OnBeforeStartDevServerFn, OnBeforeStartPreviewServerFn, OnCloseBuildFn, OnCloseDevServerFn, OnDevCompileDoneFn, OnExitFn, OutputConfig, OverlayOptions, OutputStructure, PerformanceConfig, PluginManager, Polyfill, PostCSSLoaderOptions, PostCSSOptions, PostCSSPlugin, PreconnectOption, PreviewOptions, PrintUrls, ProcessAssetsDescriptor, ProcessAssetsHandler, ProcessAssetsHook, ProgressBarConfig, ProxyBypass, ProxyConfig, ProxyFilter, ProxyOptions, PublicDir, PublicDirOptions, RequestHandler, ResolveConfig, ResolvedCreateRsbuildOptions, ResolveHandler, ResolveHook, ResourceHintsIncludeType, RsbuildConfig, RsbuildContext, RsbuildEntry, RsbuildEntryDescription, RsbuildInstance, RsbuildMode, RsbuildPlugin, RsbuildPluginAPI, RsbuildPlugins, RsbuildTarget, RspackChain, RspackRule, ScriptInject, ScriptLoading, SecurityConfig, ServerConfig, SetupMiddlewaresContext, SetupMiddlewaresFn, SourceConfig, SourceMap, SourceMapExtract, SourceMapExtractOptions, SourceMapExtractTarget, SplitChunks, SplitChunksConfig, SplitChunksPreset, SriAlgorithm, SriOptions, StartDevServerOptions, StyleLoaderOptions, ToolsConfig, TransformContext, TransformDescriptor, TransformHandler, TransformHook, TransformImport, WatchFiles, } from './types';
|
|
23
|
+
export type { AliasStrategy, AppIcon, AppIconItem, AutoExternal, AutoExternalExclude, Build, BuildOptions, BuildResult, Charset, CleanDistPath, CleanDistPathObject, ClientConfig, CliShortcut, CompressOptions, ConfigChain, ConfigChainWithContext, Connect, ConsoleType, CreateCompiler, CreateRsbuildOptions, CrossOrigin, CSSLoaderOptions, CSSModules, CSSModulesLocalsConvention, DataUriLimit, Decorators, DevConfig, DistPathConfig, EnvironmentConfig, EnvironmentContext, FilenameConfig, FilenameHash, HistoryApiFallbackContext, HistoryApiFallbackOptions, HtmlBasicTag, HtmlConfig, HtmlFallback, HtmlRspackPlugin, HtmlTag, HtmlTagContext, HtmlTagDescriptor, HtmlTagHandler, InitConfigsOptions, InlineChunkConfig, InlineChunkTest, InlineChunkTestFunction, InspectConfigOptions, InspectConfigResult, InternalContext, LegalComments, LogLevel, ManifestConfig, ManifestData, ManifestObjectConfig, MergedEnvironmentConfig, MetaAttrs, MetaOptions, Minify, ModifyBundlerChainFn, ModifyBundlerChainUtils, ModifyChainUtils, ModifyEnvironmentConfigFn, ModifyEnvironmentConfigUtils, ModifyHTMLContext, ModifyHTMLFn, ModifyHTMLTagsContext, ModifyHTMLTagsFn, ModifyRsbuildConfigFn, ModifyRsbuildConfigUtils, ModifyRspackConfigFn, ModifyRspackConfigUtils, ModuleFederationConfig, NormalizedConfig, NormalizedDevConfig, NormalizedEnvironmentConfig, NormalizedHtmlConfig, NormalizedModuleFederationConfig, NormalizedOutputConfig, NormalizedPerformanceConfig, NormalizedResolveConfig, NormalizedSecurityConfig, NormalizedServerConfig, NormalizedSourceConfig, NormalizedSplitChunksConfig, NormalizedToolsConfig, OnAfterBuildFn, OnAfterCreateCompilerFn, OnAfterDevCompileFn, OnAfterEnvironmentCompileFn, OnAfterStartDevServerFn, OnAfterStartPreviewServerFn, OnBeforeBuildFn, OnBeforeCreateCompilerFn, OnBeforeDevCompileFn, OnBeforeEnvironmentCompileFn, OnBeforeStartDevServerFn, OnBeforeStartPreviewServerFn, OnCloseBuildFn, OnCloseDevServerFn, OnDevCompileDoneFn, OnExitFn, OutputConfig, OverlayOptions, OutputStructure, PerformanceConfig, PluginManager, Polyfill, PostCSSLoaderOptions, PostCSSOptions, PostCSSPlugin, PreconnectOption, PreviewOptions, PrintUrls, ProcessAssetsDescriptor, ProcessAssetsHandler, ProcessAssetsHook, ProgressBarConfig, ProxyBypass, ProxyConfig, ProxyFilter, ProxyOptions, PublicDir, PublicDirOptions, RequestHandler, ResolveConfig, ResolvedCreateRsbuildOptions, ResolveHandler, ResolveHook, ResourceHintsIncludeType, RsbuildConfig, RsbuildContext, RsbuildEntry, RsbuildEntryDescription, RsbuildInstance, RsbuildMode, RsbuildPlugin, RsbuildPluginAPI, RsbuildPlugins, RsbuildTarget, RspackChain, RspackRule, ScriptInject, ScriptLoading, SecurityConfig, ServerConfig, SetupMiddlewaresContext, SetupMiddlewaresFn, SourceConfig, SourceMap, SourceMapExtract, SourceMapExtractOptions, SourceMapExtractTarget, SplitChunks, SplitChunksConfig, SplitChunksPreset, SriAlgorithm, SriOptions, StartDevServerOptions, StyleLoaderOptions, ToolsConfig, TransformContext, TransformDescriptor, TransformHandler, TransformHook, TransformImport, WatchFiles, } from './types';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { CSSLoaderOptions, NormalizedEnvironmentConfig, RsbuildPlugin, Rspack } from '../types';
|
|
2
|
-
export declare function getLightningCSSLoaderOptions(config: NormalizedEnvironmentConfig, targets: string[], minify: boolean): Rspack.LightningcssLoaderOptions
|
|
2
|
+
export declare function getLightningCSSLoaderOptions(config: NormalizedEnvironmentConfig, targets: string[], minify: boolean): Promise<Rspack.LightningcssLoaderOptions>;
|
|
3
3
|
export declare const normalizeCssLoaderOptions: (options: CSSLoaderOptions, exportOnlyLocals: boolean) => CSSLoaderOptions;
|
|
4
4
|
export declare const pluginCss: () => RsbuildPlugin;
|
|
@@ -5,5 +5,5 @@ export declare const composeAutoExternalRules: (options: {
|
|
|
5
5
|
autoExternal?: AutoExternal;
|
|
6
6
|
pkgJson?: PackageJson;
|
|
7
7
|
userExternals?: Externals;
|
|
8
|
-
}) =>
|
|
8
|
+
}) => RegExp[] | undefined;
|
|
9
9
|
export declare function pluginExternals(): RsbuildPlugin;
|
|
@@ -26,8 +26,9 @@ export type ServerStartResult<T> = {
|
|
|
26
26
|
export type StartDevServerResult = ServerStartResult<RsbuildDevServer>;
|
|
27
27
|
export type StartPreviewServerResult = ServerStartResult<RsbuildPreviewServer>;
|
|
28
28
|
export declare const normalizeUrl: (url: string) => string;
|
|
29
|
-
export declare const
|
|
30
|
-
export declare const
|
|
29
|
+
export declare const joinUrlPath: (basePath: string, pathname: string) => string;
|
|
30
|
+
export declare const isUrlPathUnderBase: (pathname: string, base: string) => boolean;
|
|
31
|
+
export declare const removeBasePath: (url: string, base: string) => string;
|
|
31
32
|
export declare const getRoutes: (context: InternalContext) => Routes;
|
|
32
33
|
export declare const formatRoutes: (entry: RsbuildEntry, base: string, distPathPrefix: string | undefined, outputStructure: OutputStructure | undefined) => Routes;
|
|
33
34
|
export declare function printServerURLs({ urls: originalUrls, port, routes, protocol, printUrls, fallbackPathname, trailingLineBreak, originalConfig, logger, }: {
|
|
@@ -16,7 +16,7 @@ import type { RsbuildPlugins } from './plugin';
|
|
|
16
16
|
import type { RsbuildEntry, RsbuildMode, RsbuildTarget } from './rsbuild';
|
|
17
17
|
import type { Rspack, RspackRule } from './rspack';
|
|
18
18
|
import type { Connect, CSSExtractOptions, CSSLoaderModulesOptions, CSSLoaderOptions, HtmlRspackPlugin, LoosePostCSSPlugin, PostCSSLoaderOptions, StyleLoaderOptions } from './thirdParty';
|
|
19
|
-
import type { ConfigChain, ConfigChainMergeContext, ConfigChainWithContext, LiteralUnion, MaybePromise, OneOrMany, Optional, TwoLevelReadonly } from './utils';
|
|
19
|
+
import type { ConfigChain, ConfigChainAsyncWithContext, ConfigChainMergeContext, ConfigChainWithContext, LiteralUnion, MaybePromise, OneOrMany, Optional, TwoLevelReadonly } from './utils';
|
|
20
20
|
export type ToolsSwcConfig = ConfigChain<SwcLoaderOptions>;
|
|
21
21
|
export type ToolsBundlerChainConfig = OneOrMany<(chain: RspackChain, utils: ModifyBundlerChainUtils) => MaybePromise<void>>;
|
|
22
22
|
export type ToolsPostCSSContext = {
|
|
@@ -39,10 +39,10 @@ export type ToolsHtmlPluginConfig = ConfigChainWithContext<HtmlRspackPlugin.Opti
|
|
|
39
39
|
}>;
|
|
40
40
|
export type RspackMerge = (firstConfiguration: Rspack.Configuration | Rspack.Configuration[], ...configurations: Rspack.Configuration[]) => Rspack.Configuration;
|
|
41
41
|
export type ModifyRspackConfigUtils = ModifyChainUtils & {
|
|
42
|
-
addRules: (rules: RspackRule
|
|
43
|
-
appendRules: (rules: RspackRule
|
|
44
|
-
prependPlugins: (plugins: Rspack.
|
|
45
|
-
appendPlugins: (plugins: Rspack.
|
|
42
|
+
addRules: (rules: OneOrMany<RspackRule>) => void;
|
|
43
|
+
appendRules: (rules: OneOrMany<RspackRule>) => void;
|
|
44
|
+
prependPlugins: (plugins: OneOrMany<Rspack.Plugin>) => void;
|
|
45
|
+
appendPlugins: (plugins: OneOrMany<Rspack.Plugin>) => void;
|
|
46
46
|
removePlugin: (pluginName: string) => void;
|
|
47
47
|
mergeConfig: RspackMerge;
|
|
48
48
|
};
|
|
@@ -78,7 +78,7 @@ export type NarrowedRspackConfig = Omit<Rspack.Configuration, 'plugins' | 'modul
|
|
|
78
78
|
/**
|
|
79
79
|
* Plugins to use during compilation.
|
|
80
80
|
*/
|
|
81
|
-
plugins:
|
|
81
|
+
plugins: Rspack.Plugin[];
|
|
82
82
|
/**
|
|
83
83
|
* Options for module configuration.
|
|
84
84
|
*/
|
|
@@ -1104,6 +1104,7 @@ export type CleanDistPathObject = {
|
|
|
1104
1104
|
keep?: RegExp[];
|
|
1105
1105
|
};
|
|
1106
1106
|
export type CleanDistPath = boolean | 'auto' | CleanDistPathObject;
|
|
1107
|
+
export type AutoExternalExclude = OneOrMany<string | RegExp>;
|
|
1107
1108
|
export type AutoExternal = boolean | {
|
|
1108
1109
|
/**
|
|
1109
1110
|
* Whether to automatically externalize dependencies of type `dependencies`.
|
|
@@ -1125,6 +1126,18 @@ export type AutoExternal = boolean | {
|
|
|
1125
1126
|
* @default false
|
|
1126
1127
|
*/
|
|
1127
1128
|
devDependencies?: boolean;
|
|
1129
|
+
/**
|
|
1130
|
+
* Specify the package.json file path(s) used to collect dependencies.
|
|
1131
|
+
* Relative paths are resolved from the Rsbuild root directory.
|
|
1132
|
+
* @default '<root>/package.json'
|
|
1133
|
+
*/
|
|
1134
|
+
packageJson?: string | string[];
|
|
1135
|
+
/**
|
|
1136
|
+
* Prevent matched packages from being automatically externalized.
|
|
1137
|
+
* Strings match package names exactly, and regular expressions test package names.
|
|
1138
|
+
* @default undefined
|
|
1139
|
+
*/
|
|
1140
|
+
exclude?: AutoExternalExclude;
|
|
1128
1141
|
};
|
|
1129
1142
|
export interface OutputConfig {
|
|
1130
1143
|
/**
|
|
@@ -1560,7 +1573,7 @@ export interface HtmlConfig {
|
|
|
1560
1573
|
* Define the parameters in the HTML template,
|
|
1561
1574
|
* corresponding to the `templateParameters` config of [html-rspack-plugin](https://github.com/rstackjs/html-rspack-plugin).
|
|
1562
1575
|
*/
|
|
1563
|
-
templateParameters?:
|
|
1576
|
+
templateParameters?: ConfigChainAsyncWithContext<Record<string, unknown>, {
|
|
1564
1577
|
entryName: string;
|
|
1565
1578
|
}>;
|
|
1566
1579
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rsbuild/core",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.8",
|
|
4
4
|
"description": "The Rspack-based build tool.",
|
|
5
5
|
"homepage": "https://rsbuild.rs",
|
|
6
6
|
"bugs": {
|
|
@@ -36,8 +36,8 @@
|
|
|
36
36
|
"types.d.ts"
|
|
37
37
|
],
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@rspack/core": "~2.0.
|
|
40
|
-
"@swc/helpers": "^0.5.
|
|
39
|
+
"@rspack/core": "~2.0.5",
|
|
40
|
+
"@swc/helpers": "^0.5.23"
|
|
41
41
|
},
|
|
42
42
|
"peerDependencies": {
|
|
43
43
|
"core-js": ">= 3.0.0"
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
"@types/on-finished": "2.3.5",
|
|
57
57
|
"@types/range-parser": "^1.2.7",
|
|
58
58
|
"@types/ws": "^8.18.1",
|
|
59
|
-
"browserslist-load-config": "1.0.1",
|
|
59
|
+
"browserslist-load-config": "^1.0.1",
|
|
60
60
|
"cac": "^7.0.0",
|
|
61
61
|
"chokidar": "^5.0.0",
|
|
62
62
|
"connect-next": "4.0.1",
|
|
@@ -64,7 +64,7 @@
|
|
|
64
64
|
"cors": "^2.8.6",
|
|
65
65
|
"css-loader": "7.1.4",
|
|
66
66
|
"deepmerge": "^4.3.1",
|
|
67
|
-
"dotenv-expand": "13.0.0",
|
|
67
|
+
"dotenv-expand": "^13.0.0",
|
|
68
68
|
"html-rspack-plugin": "6.1.8",
|
|
69
69
|
"http-proxy-middleware": "4.0.0",
|
|
70
70
|
"jiti": "^2.7.0",
|
|
@@ -73,12 +73,12 @@
|
|
|
73
73
|
"mrmime": "^2.0.1",
|
|
74
74
|
"on-finished": "2.4.1",
|
|
75
75
|
"open": "^11.0.0",
|
|
76
|
-
"postcss": "^8.5.
|
|
76
|
+
"postcss": "^8.5.15",
|
|
77
77
|
"postcss-load-config": "6.0.1",
|
|
78
78
|
"postcss-loader": "8.2.1",
|
|
79
79
|
"prebundle": "1.6.4",
|
|
80
80
|
"range-parser": "^1.2.1",
|
|
81
|
-
"reduce-configs": "^
|
|
81
|
+
"reduce-configs": "^2.0.0",
|
|
82
82
|
"rslog": "^2.1.1",
|
|
83
83
|
"rspack-chain": "^2.0.1",
|
|
84
84
|
"rspack-manifest-plugin": "5.2.1",
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
"style-loader": "^4.0.0",
|
|
89
89
|
"tinyglobby": "^0.2.16",
|
|
90
90
|
"typescript": "^6.0.3",
|
|
91
|
-
"ws": "^8.
|
|
91
|
+
"ws": "^8.21.0"
|
|
92
92
|
},
|
|
93
93
|
"engines": {
|
|
94
94
|
"node": "^20.19.0 || >=22.12.0"
|
|
File without changes
|
|
File without changes
|