@ohos-ports/rsbuild-core 2.2.13-beta.0 → 2.3.3-beta.0
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/README.md +7 -9
- package/compiled/@rstackjs/load-config/index.d.ts +10 -1
- package/compiled/@rstackjs/load-config/package.json +1 -1
- package/compiled/chokidar/index.d.ts +448 -161
- package/compiled/chokidar/package.json +1 -1
- package/compiled/css-loader/index.js +2 -2
- package/compiled/html-rspack-plugin/index.js +14 -14
- package/compiled/http-proxy-middleware/index.d.ts +10 -10
- package/compiled/http-proxy-middleware/package.json +1 -1
- package/compiled/jiti/dist/babel.cjs +1 -1
- package/compiled/postcss/index.js +1 -1
- package/compiled/postcss/lib/declaration.d.ts +2 -2
- package/compiled/postcss/package.json +1 -1
- package/compiled/postcss-loader/index.js +6 -6
- package/compiled/rspack-chain/package.json +1 -1
- package/compiled/rspack-chain/types/index.d.ts +1 -0
- package/dist/1.js +1 -0
- package/dist/chokidar.js +1 -1
- package/dist/client/hmr.js +26 -8
- package/dist/client/overlay.js +6 -5
- package/dist/defaultConfig.d.ts +7 -2
- package/dist/helpers/compilation.d.ts +2 -0
- package/dist/helpers/stats.d.ts +1 -0
- package/dist/helpers/workspace.d.ts +1 -0
- package/dist/hooks.d.ts +2 -1
- package/dist/http-proxy-middleware.js +4 -4
- package/dist/index.d.ts +1 -1
- package/dist/m.js +1515 -1387
- package/dist/m.js.LICENSE.txt +0 -13
- package/dist/manifest-plugin.js +1 -1
- package/dist/memfs.js +1 -1
- package/dist/open.js +2 -2
- package/dist/server/assets-middleware/getFileFromUrl.d.ts +3 -1
- package/dist/server/assets-middleware/index.d.ts +2 -1
- package/dist/server/assets-middleware/middleware.d.ts +4 -6
- package/dist/server/assets-middleware/setupMemoryFileSystemCleanup.d.ts +3 -0
- package/dist/server/devMiddlewares.d.ts +1 -1
- package/dist/server/helper.d.ts +5 -2
- package/dist/server/socketServer.d.ts +18 -2
- package/dist/server/watchFiles.d.ts +3 -1
- package/dist/sirv.js +3 -2
- package/dist/transformLoader.mjs +10 -10
- package/dist/transformRawLoader.mjs +2 -2
- package/dist/types/config.d.ts +17 -4
- package/dist/types/hooks.d.ts +1 -0
- package/dist/types/plugin.d.ts +26 -4
- package/dist/types/rsbuild.d.ts +1 -1
- package/dist/workerLoader.mjs +3 -3
- package/dist/ws.js +2 -2
- package/package.json +5 -5
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
(() => {
|
|
2
2
|
var __webpack_modules__ = {
|
|
3
|
-
|
|
3
|
+
428: (module, __unused_webpack_exports, __nccwpck_require__) => {
|
|
4
4
|
"use strict";
|
|
5
|
-
const { HtmlWebpackChildCompiler } = __nccwpck_require__(
|
|
5
|
+
const { HtmlWebpackChildCompiler } = __nccwpck_require__(297);
|
|
6
6
|
const compilerMap = new WeakMap();
|
|
7
7
|
class CachedChildCompilation {
|
|
8
8
|
constructor(compiler) {
|
|
@@ -307,7 +307,7 @@
|
|
|
307
307
|
}
|
|
308
308
|
module.exports = { CachedChildCompilation };
|
|
309
309
|
},
|
|
310
|
-
|
|
310
|
+
297: (module) => {
|
|
311
311
|
"use strict";
|
|
312
312
|
class HtmlWebpackChildCompiler {
|
|
313
313
|
compilationPromise;
|
|
@@ -476,7 +476,7 @@
|
|
|
476
476
|
}
|
|
477
477
|
module.exports = { HtmlWebpackChildCompiler };
|
|
478
478
|
},
|
|
479
|
-
|
|
479
|
+
455: (module) => {
|
|
480
480
|
"use strict";
|
|
481
481
|
function none(chunks) {
|
|
482
482
|
return chunks;
|
|
@@ -492,7 +492,7 @@
|
|
|
492
492
|
}
|
|
493
493
|
module.exports = { auto: none, manual, none };
|
|
494
494
|
},
|
|
495
|
-
|
|
495
|
+
34: (module) => {
|
|
496
496
|
"use strict";
|
|
497
497
|
module.exports = function (err) {
|
|
498
498
|
return {
|
|
@@ -516,7 +516,7 @@
|
|
|
516
516
|
};
|
|
517
517
|
};
|
|
518
518
|
},
|
|
519
|
-
|
|
519
|
+
649: (module, __unused_webpack_exports, __nccwpck_require__) => {
|
|
520
520
|
"use strict";
|
|
521
521
|
const { AsyncSeriesWaterfallHook } = __nccwpck_require__(537);
|
|
522
522
|
const htmlWebpackPluginHooksMap = new WeakMap();
|
|
@@ -542,7 +542,7 @@
|
|
|
542
542
|
}
|
|
543
543
|
module.exports = { getHtmlRspackPluginHooks };
|
|
544
544
|
},
|
|
545
|
-
|
|
545
|
+
136: (module) => {
|
|
546
546
|
const voidTags = [
|
|
547
547
|
"area",
|
|
548
548
|
"base",
|
|
@@ -610,19 +610,19 @@
|
|
|
610
610
|
htmlTagObjectToString,
|
|
611
611
|
};
|
|
612
612
|
},
|
|
613
|
-
|
|
613
|
+
629: (module, __unused_webpack_exports, __nccwpck_require__) => {
|
|
614
614
|
"use strict";
|
|
615
615
|
const promisify = __nccwpck_require__(23).promisify;
|
|
616
616
|
const vm = __nccwpck_require__(154);
|
|
617
617
|
const fs = __nccwpck_require__(896);
|
|
618
618
|
const path = __nccwpck_require__(928);
|
|
619
|
-
const { CachedChildCompilation } = __nccwpck_require__(
|
|
619
|
+
const { CachedChildCompilation } = __nccwpck_require__(428);
|
|
620
620
|
const { createHtmlTagObject, htmlTagObjectToString, HtmlTagArray } =
|
|
621
|
-
__nccwpck_require__(
|
|
622
|
-
const prettyError = __nccwpck_require__(
|
|
623
|
-
const chunkSorter = __nccwpck_require__(
|
|
621
|
+
__nccwpck_require__(136);
|
|
622
|
+
const prettyError = __nccwpck_require__(34);
|
|
623
|
+
const chunkSorter = __nccwpck_require__(455);
|
|
624
624
|
const getHtmlRspackPluginHooks =
|
|
625
|
-
__nccwpck_require__(
|
|
625
|
+
__nccwpck_require__(649).getHtmlRspackPluginHooks;
|
|
626
626
|
const WITH_PLACEHOLDER = "function __with_placeholder__";
|
|
627
627
|
class HtmlRspackPlugin {
|
|
628
628
|
constructor(userOptions = {}) {
|
|
@@ -2445,6 +2445,6 @@
|
|
|
2445
2445
|
}
|
|
2446
2446
|
if (typeof __nccwpck_require__ !== "undefined")
|
|
2447
2447
|
__nccwpck_require__.ab = __dirname + "/";
|
|
2448
|
-
var __webpack_exports__ = __nccwpck_require__(
|
|
2448
|
+
var __webpack_exports__ = __nccwpck_require__(629);
|
|
2449
2449
|
module.exports = __webpack_exports__;
|
|
2450
2450
|
})();
|
|
@@ -136,7 +136,7 @@ declare class ProxyServer<Req extends http__default.IncomingMessage | http2.Http
|
|
|
136
136
|
* https://github.com/DefinitelyTyped/DefinitelyTyped/blob/6f529c6c67a447190f86bfbf894d1061e41e07b7/types/http-proxy-middleware/index.d.ts
|
|
137
137
|
*/
|
|
138
138
|
|
|
139
|
-
type NextFunction<T = (err?:
|
|
139
|
+
type NextFunction<T = (err?: unknown) => void> = T;
|
|
140
140
|
interface RequestHandler<TReq extends http.IncomingMessage = http.IncomingMessage, TRes extends http.ServerResponse = http.ServerResponse, TNext = NextFunction> {
|
|
141
141
|
(req: TReq, res: TRes, next?: TNext): Promise<void>;
|
|
142
142
|
upgrade: (req: TReq, socket: net.Socket, head: Buffer) => void;
|
|
@@ -149,15 +149,15 @@ interface Plugin<TReq extends http.IncomingMessage = http.IncomingMessage, TRes
|
|
|
149
149
|
(proxyServer: ProxyServer<TReq, TRes>, options: Options<TReq, TRes>): void;
|
|
150
150
|
}
|
|
151
151
|
interface OnProxyEvent<TReq extends http.IncomingMessage = http.IncomingMessage, TRes extends http.ServerResponse = http.ServerResponse> {
|
|
152
|
-
error?: (err: Error, req: TReq, res: TRes | net.Socket, target?:
|
|
152
|
+
error?: (err: Error, req: TReq, res: TRes | net.Socket, target?: ProxyTarget) => void;
|
|
153
153
|
proxyReq?: (proxyReq: http.ClientRequest, req: TReq, res: TRes, options: ProxyServerOptions) => void;
|
|
154
|
-
proxyReqWs?: (proxyReq: http.ClientRequest, req: TReq, socket: net.Socket, options: ProxyServerOptions, head:
|
|
154
|
+
proxyReqWs?: (proxyReq: http.ClientRequest, req: TReq, socket: net.Socket, options: ProxyServerOptions, head: Buffer) => void;
|
|
155
155
|
proxyRes?: (proxyRes: TReq, req: TReq, res: TRes) => void | Promise<void>;
|
|
156
156
|
open?: (proxySocket: net.Socket) => void;
|
|
157
|
-
close?: (proxyRes: TReq, proxySocket: net.Socket, proxyHead:
|
|
158
|
-
start?: (req: TReq, res: TRes, target:
|
|
157
|
+
close?: (proxyRes: TReq, proxySocket: net.Socket, proxyHead: Buffer) => void;
|
|
158
|
+
start?: (req: TReq, res: TRes, target: ProxyTarget) => void;
|
|
159
159
|
end?: (req: TReq, res: TRes, proxyRes: TReq) => void;
|
|
160
|
-
econnreset?: (err: Error, req: TReq, res: TRes, target:
|
|
160
|
+
econnreset?: (err: Error, req: TReq, res: TRes, target: ProxyTarget) => void;
|
|
161
161
|
}
|
|
162
162
|
type Logger = Pick<Console, 'info' | 'warn' | 'error'>;
|
|
163
163
|
type PathRewriteConfig<TReq extends http.IncomingMessage = http.IncomingMessage, TRes extends http.ServerResponse = http.ServerResponse> = {
|
|
@@ -254,7 +254,7 @@ interface Options<TReq extends http.IncomingMessage = http.IncomingMessage, TRes
|
|
|
254
254
|
*
|
|
255
255
|
* @link https://github.com/chimurai/http-proxy-middleware/blob/master/recipes/router.md
|
|
256
256
|
*/
|
|
257
|
-
router?: Record<string,
|
|
257
|
+
router?: Record<string, ProxyTarget> | ((req: TReq, res: TRes | undefined, options: Options<TReq, TRes>) => ProxyTarget) | ((req: TReq, res: TRes | undefined, options: Options<TReq, TRes>) => Promise<ProxyTarget>);
|
|
258
258
|
/**
|
|
259
259
|
* Log information from http-proxy-middleware
|
|
260
260
|
* @example
|
|
@@ -345,7 +345,7 @@ interface Options<TReq extends http.IncomingMessage = http.IncomingMessage, TRes
|
|
|
345
345
|
* @see https://github.com/chimurai/http-proxy-middleware/blob/master/recipes/pathRewrite.md
|
|
346
346
|
* @see https://github.com/chimurai/http-proxy-middleware/blob/master/recipes/response-interceptor.md
|
|
347
347
|
*/
|
|
348
|
-
declare function createProxyMiddleware<TReq extends http.IncomingMessage = http.IncomingMessage, TRes extends http.ServerResponse = http.ServerResponse, TNext = NextFunction>(options: Options<TReq, TRes>): RequestHandler<TReq, TRes, TNext>;
|
|
348
|
+
declare function createProxyMiddleware<TReq extends http.IncomingMessage = http.IncomingMessage, TRes extends http.ServerResponse = http.ServerResponse, TNext extends (err?: unknown) => void = NextFunction>(options: Options<TReq, TRes>): RequestHandler<TReq, TRes, TNext>;
|
|
349
349
|
|
|
350
350
|
type Interceptor<TReq = http.IncomingMessage, TRes = http.ServerResponse> = (buffer: Buffer, proxyRes: http.IncomingMessage, req: TReq, res: TRes) => Promise<Buffer | string>;
|
|
351
351
|
/**
|
|
@@ -373,8 +373,8 @@ type Interceptor<TReq = http.IncomingMessage, TRes = http.ServerResponse> = (buf
|
|
|
373
373
|
*/
|
|
374
374
|
declare function responseInterceptor<TReq extends http.IncomingMessage = http.IncomingMessage, TRes extends http.ServerResponse = http.ServerResponse>(interceptor: Interceptor<TReq, TRes>): (proxyRes: http.IncomingMessage, req: TReq, res: TRes) => Promise<void>;
|
|
375
375
|
|
|
376
|
-
type BodyParserLikeRequest = http.IncomingMessage & {
|
|
377
|
-
body?:
|
|
376
|
+
type BodyParserLikeRequest<TBody = unknown> = http.IncomingMessage & {
|
|
377
|
+
body?: TBody;
|
|
378
378
|
};
|
|
379
379
|
/**
|
|
380
380
|
* Fix proxied body if bodyParser is involved.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"http-proxy-middleware","author":"Steven Chim","version":"4.2.
|
|
1
|
+
{"name":"http-proxy-middleware","author":"Steven Chim","version":"4.2.1","license":"MIT","types":"index.d.ts","type":"module"}
|
|
@@ -2008,7 +2008,7 @@
|
|
|
2008
2008
|
if (t.minimal && !l.test(e)) return e;
|
|
2009
2009
|
const d = hexadecimal(e.charCodeAt(0), y);
|
|
2010
2010
|
return u || d.length > 2 ? fourHexEscape(d) : "\\x" + ("00" + d).slice(-2);
|
|
2011
|
-
}), "`" == m && (T = T.replace(/\$\{/g, "\\${")), t.isScriptContext && (T = T.replace(/<\/(script|style)/gi, "<\\/$1").replace(
|
|
2011
|
+
}), "`" == m && (T = T.replace(/\$\{/g, "\\${")), t.isScriptContext && (T = T.replace(/<\/(script|style)/gi, "<\\/$1").replace(/<\x21--/g, u ? "\\u003C!--" : "\\x3C!--")), t.wrap && (T = m + T + m), T;
|
|
2012
2012
|
};
|
|
2013
2013
|
jsesc.version = "3.0.2", e.exports = jsesc;
|
|
2014
2014
|
},
|