@rsbuild/core 2.1.4 → 2.1.5

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.
@@ -1,8 +1,8 @@
1
1
  (() => {
2
2
  var __webpack_modules__ = {
3
- 776: (module, __unused_webpack_exports, __nccwpck_require__) => {
3
+ 523: (module, __unused_webpack_exports, __nccwpck_require__) => {
4
4
  "use strict";
5
- const { HtmlWebpackChildCompiler } = __nccwpck_require__(469);
5
+ const { HtmlWebpackChildCompiler } = __nccwpck_require__(288);
6
6
  const compilerMap = new WeakMap();
7
7
  class CachedChildCompilation {
8
8
  constructor(compiler) {
@@ -311,7 +311,7 @@
311
311
  }
312
312
  module.exports = { CachedChildCompilation };
313
313
  },
314
- 469: (module) => {
314
+ 288: (module) => {
315
315
  "use strict";
316
316
  class HtmlWebpackChildCompiler {
317
317
  constructor(templates) {
@@ -480,7 +480,7 @@
480
480
  }
481
481
  module.exports = { HtmlWebpackChildCompiler };
482
482
  },
483
- 67: (module) => {
483
+ 872: (module) => {
484
484
  "use strict";
485
485
  module.exports = {};
486
486
  module.exports.none = (chunks) => chunks;
@@ -499,7 +499,7 @@
499
499
  };
500
500
  module.exports.auto = module.exports.none;
501
501
  },
502
- 262: (module) => {
502
+ 511: (module) => {
503
503
  "use strict";
504
504
  module.exports = function (err) {
505
505
  return {
@@ -523,7 +523,7 @@
523
523
  };
524
524
  };
525
525
  },
526
- 917: (module, __unused_webpack_exports, __nccwpck_require__) => {
526
+ 206: (module, __unused_webpack_exports, __nccwpck_require__) => {
527
527
  "use strict";
528
528
  const { AsyncSeriesWaterfallHook } = __nccwpck_require__(159);
529
529
  const htmlWebpackPluginHooksMap = new WeakMap();
@@ -549,7 +549,7 @@
549
549
  }
550
550
  module.exports = { getHtmlRspackPluginHooks };
551
551
  },
552
- 492: (module) => {
552
+ 355: (module) => {
553
553
  const voidTags = [
554
554
  "area",
555
555
  "base",
@@ -617,19 +617,19 @@
617
617
  htmlTagObjectToString,
618
618
  };
619
619
  },
620
- 345: (module, __unused_webpack_exports, __nccwpck_require__) => {
620
+ 474: (module, __unused_webpack_exports, __nccwpck_require__) => {
621
621
  "use strict";
622
622
  const promisify = __nccwpck_require__(23).promisify;
623
623
  const vm = __nccwpck_require__(154);
624
624
  const fs = __nccwpck_require__(896);
625
625
  const path = __nccwpck_require__(928);
626
- const { CachedChildCompilation } = __nccwpck_require__(776);
626
+ const { CachedChildCompilation } = __nccwpck_require__(523);
627
627
  const { createHtmlTagObject, htmlTagObjectToString, HtmlTagArray } =
628
- __nccwpck_require__(492);
629
- const prettyError = __nccwpck_require__(262);
630
- const chunkSorter = __nccwpck_require__(67);
628
+ __nccwpck_require__(355);
629
+ const prettyError = __nccwpck_require__(511);
630
+ const chunkSorter = __nccwpck_require__(872);
631
631
  const getHtmlRspackPluginHooks =
632
- __nccwpck_require__(917).getHtmlRspackPluginHooks;
632
+ __nccwpck_require__(206).getHtmlRspackPluginHooks;
633
633
  const WITH_PLACEHOLDER = "function __with_placeholder__";
634
634
  class HtmlRspackPlugin {
635
635
  constructor(userOptions = {}) {
@@ -2398,6 +2398,6 @@
2398
2398
  }
2399
2399
  if (typeof __nccwpck_require__ !== "undefined")
2400
2400
  __nccwpck_require__.ab = __dirname + "/";
2401
- var __webpack_exports__ = __nccwpck_require__(345);
2401
+ var __webpack_exports__ = __nccwpck_require__(474);
2402
2402
  module.exports = __webpack_exports__;
2403
2403
  })();
@@ -11,6 +11,7 @@ interface ProxyTargetDetailed {
11
11
  port?: number | string;
12
12
  protocol?: string;
13
13
  hostname?: string;
14
+ pathname?: string;
14
15
  socketPath?: string;
15
16
  key?: string;
16
17
  passphrase?: string;
@@ -451,4 +452,4 @@ declare const loggerPlugin: Plugin;
451
452
  declare const proxyEventsPlugin: Plugin;
452
453
 
453
454
  export { createProxyMiddleware, debugProxyErrorsPlugin, definePlugin, errorResponsePlugin, fixRequestBody, loggerPlugin, proxyEventsPlugin, responseInterceptor };
454
- export type { Filter, Options, Plugin, RequestHandler };
455
+ export type { Filter, OnProxyEvent, Options, Plugin, RequestHandler };
@@ -1 +1 @@
1
- {"name":"http-proxy-middleware","author":"Steven Chim","version":"4.1.1","license":"MIT","types":"index.d.ts","type":"module"}
1
+ {"name":"http-proxy-middleware","author":"Steven Chim","version":"4.2.0","license":"MIT","types":"index.d.ts","type":"module"}
@@ -28309,8 +28309,7 @@
28309
28309
  n
28310
28310
  ])[0]);
28311
28311
  }, t.getFirstIdentifier = getFirstIdentifier;
28312
- var n = r("./node_modules/.pnpm/@babel+core@7.29.0/node_modules/@babel/core/lib/index.js"), s = r("./node_modules/.pnpm/@babel+plugin-transform-typescript@7.28.6_@babel+core@7.29.0/node_modules/@babel/plugin-transform-typescript/lib/global-types.js");
28313
- r("./node_modules/.pnpm/@babel+plugin-transform-typescript@7.28.6_@babel+core@7.29.0/node_modules/@babel/plugin-transform-typescript/lib/const-enum.js");
28312
+ var n = r("./node_modules/.pnpm/@babel+core@7.29.0/node_modules/@babel/core/lib/index.js"), s = r("./node_modules/.pnpm/@babel+plugin-transform-typescript@7.28.6_@babel+core@7.29.0/node_modules/@babel/plugin-transform-typescript/lib/global-types.js"), i = r("./node_modules/.pnpm/@babel+plugin-transform-typescript@7.28.6_@babel+core@7.29.0/node_modules/@babel/plugin-transform-typescript/lib/const-enum.js");
28314
28313
  function getFirstIdentifier(e1) {
28315
28314
  return n.types.isIdentifier(e1) ? e1 : getFirstIdentifier(e1.left);
28316
28315
  }
@@ -28319,6 +28318,25 @@
28319
28318
  n.types.variableDeclarator(n.types.identifier(e1))
28320
28319
  ]);
28321
28320
  }
28321
+ function getMemberExpression(e1, t) {
28322
+ return n.types.memberExpression(n.types.identifier(e1), n.types.identifier(t));
28323
+ }
28324
+ function handleVariableDeclaration(e1, t, r) {
28325
+ if ("const" !== e1.kind) throw r.file.buildCodeFrameError(e1, "Namespaces exporting non-const are not supported by Babel. Change to const or see: https://babeljs.io/docs/en/babel-plugin-transform-typescript");
28326
+ const { declarations: s } = e1;
28327
+ if (s.every((e1)=>n.types.isIdentifier(e1.id))) {
28328
+ for (const e1 of s)e1.init = n.types.assignmentExpression("=", getMemberExpression(t, e1.id.name), e1.init);
28329
+ return [
28330
+ e1
28331
+ ];
28332
+ }
28333
+ const i = n.types.getBindingIdentifiers(e1), o = [];
28334
+ for(const e1 in i)o.push(n.types.assignmentExpression("=", getMemberExpression(t, e1), n.types.cloneNode(i[e1])));
28335
+ return [
28336
+ e1,
28337
+ n.types.expressionStatement(n.types.sequenceExpression(o))
28338
+ ];
28339
+ }
28322
28340
  function buildNestedAmbientModuleError(e1, t) {
28323
28341
  return e1.hub.buildError(t, "Ambient modules cannot be nested in other modules or namespaces.", Error);
28324
28342
  }
@@ -28358,6 +28376,35 @@
28358
28376
  continue;
28359
28377
  case "ExportNamedDeclaration":
28360
28378
  }
28379
+ if (!("declare" in r.declaration) || !r.declaration.declare) switch(r.declaration.type){
28380
+ case "TSEnumDeclaration":
28381
+ i.EXPORTED_CONST_ENUMS_IN_NAMESPACE.add(r.declaration);
28382
+ case "FunctionDeclaration":
28383
+ case "ClassDeclaration":
28384
+ {
28385
+ c = !1;
28386
+ const e1 = r.declaration.id.name;
28387
+ s.add(e1), p.splice(t++, 1, r.declaration, n.types.expressionStatement(n.types.assignmentExpression("=", getMemberExpression(a, e1), n.types.identifier(e1))));
28388
+ break;
28389
+ }
28390
+ case "VariableDeclaration":
28391
+ {
28392
+ c = !1;
28393
+ const n = handleVariableDeclaration(r.declaration, a, e1.hub);
28394
+ p.splice(t, n.length, ...n), t += n.length - 1;
28395
+ break;
28396
+ }
28397
+ case "TSModuleDeclaration":
28398
+ {
28399
+ if (!n.types.isIdentifier(r.declaration.id)) throw buildNestedAmbientModuleError(e1, r.declaration);
28400
+ const i = handleNested(e1, r.declaration, n.types.identifier(a));
28401
+ if (null !== i) {
28402
+ c = !1;
28403
+ const e1 = r.declaration.id.name;
28404
+ s.has(e1) ? p[t] = i : (s.add(e1), p.splice(t++, 1, getDeclaration(e1), i));
28405
+ } else p.splice(t, 1), t--;
28406
+ }
28407
+ }
28361
28408
  }
28362
28409
  if (c) return null;
28363
28410
  let u = n.types.objectExpression([]);