@rsbuild/core 1.0.3 → 1.0.4

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/dist/index.cjs CHANGED
@@ -2304,7 +2304,7 @@ async function createContext(options, userConfig, bundlerType) {
2304
2304
  const rsbuildConfig = await withDefaultConfig(rootPath, userConfig);
2305
2305
  const cachePath = (0, import_node_path9.join)(rootPath, "node_modules", ".cache");
2306
2306
  return {
2307
- version: "1.0.3",
2307
+ version: "1.0.4",
2308
2308
  rootPath,
2309
2309
  distPath: "",
2310
2310
  cachePath,
@@ -4184,7 +4184,11 @@ var init_helper = __esm({
4184
4184
  init_helpers();
4185
4185
  init_logger();
4186
4186
  normalizeUrl = (url2) => url2.replace(/([^:]\/)\/+/g, "$1");
4187
- formatPrefix = (prefix) => {
4187
+ formatPrefix = (input) => {
4188
+ let prefix = input;
4189
+ if (prefix?.startsWith("./")) {
4190
+ prefix = prefix.replace("./", "");
4191
+ }
4188
4192
  if (!prefix) {
4189
4193
  return "/";
4190
4194
  }
@@ -9675,7 +9679,7 @@ var init_init = __esm({
9675
9679
 
9676
9680
  // src/cli/commands.ts
9677
9681
  function runCli() {
9678
- import_commander.program.name("rsbuild").usage("<command> [options]").version("1.0.3");
9682
+ import_commander.program.name("rsbuild").usage("<command> [options]").version("1.0.4");
9679
9683
  const devCommand = import_commander.program.command("dev");
9680
9684
  const buildCommand = import_commander.program.command("build");
9681
9685
  const previewCommand = import_commander.program.command("preview");
@@ -9798,7 +9802,7 @@ function prepareCli() {
9798
9802
  if (!npm_execpath || npm_execpath.includes("npx-cli.js") || npm_execpath.includes(".bun")) {
9799
9803
  console.log();
9800
9804
  }
9801
- import_rslog.logger.greet(` ${`Rsbuild v${"1.0.3"}`}
9805
+ import_rslog.logger.greet(` ${`Rsbuild v${"1.0.4"}`}
9802
9806
  `);
9803
9807
  }
9804
9808
  var init_prepare = __esm({
@@ -9882,7 +9886,7 @@ init_logger();
9882
9886
  init_mergeConfig();
9883
9887
  init_helpers();
9884
9888
  init_constants();
9885
- var version = "1.0.3";
9889
+ var version = "1.0.4";
9886
9890
  // Annotate the CommonJS export names for ESM import in node:
9887
9891
  0 && (module.exports = {
9888
9892
  PLUGIN_CSS_NAME,
package/dist/index.js CHANGED
@@ -2342,7 +2342,7 @@ async function createContext(options, userConfig, bundlerType) {
2342
2342
  const rsbuildConfig = await withDefaultConfig(rootPath, userConfig);
2343
2343
  const cachePath = join6(rootPath, "node_modules", ".cache");
2344
2344
  return {
2345
- version: "1.0.3",
2345
+ version: "1.0.4",
2346
2346
  rootPath,
2347
2347
  distPath: "",
2348
2348
  cachePath,
@@ -4238,7 +4238,11 @@ var init_helper = __esm({
4238
4238
  init_helpers();
4239
4239
  init_logger();
4240
4240
  normalizeUrl = (url2) => url2.replace(/([^:]\/)\/+/g, "$1");
4241
- formatPrefix = (prefix) => {
4241
+ formatPrefix = (input) => {
4242
+ let prefix = input;
4243
+ if (prefix?.startsWith("./")) {
4244
+ prefix = prefix.replace("./", "");
4245
+ }
4242
4246
  if (!prefix) {
4243
4247
  return "/";
4244
4248
  }
@@ -9784,7 +9788,7 @@ import { existsSync } from "fs";
9784
9788
  import { program } from "../compiled/commander/index.js";
9785
9789
  import color16 from "../compiled/picocolors/index.js";
9786
9790
  function runCli() {
9787
- program.name("rsbuild").usage("<command> [options]").version("1.0.3");
9791
+ program.name("rsbuild").usage("<command> [options]").version("1.0.4");
9788
9792
  const devCommand = program.command("dev");
9789
9793
  const buildCommand = program.command("build");
9790
9794
  const previewCommand = program.command("preview");
@@ -9905,7 +9909,7 @@ function prepareCli() {
9905
9909
  if (!npm_execpath || npm_execpath.includes("npx-cli.js") || npm_execpath.includes(".bun")) {
9906
9910
  console.log();
9907
9911
  }
9908
- logger.greet(` ${`Rsbuild v${"1.0.3"}`}
9912
+ logger.greet(` ${`Rsbuild v${"1.0.4"}`}
9909
9913
  `);
9910
9914
  }
9911
9915
  var init_prepare = __esm({
@@ -9976,7 +9980,7 @@ init_mergeConfig();
9976
9980
  init_helpers();
9977
9981
  init_constants();
9978
9982
  import { rspack as rspack10 } from "@rspack/core";
9979
- var version = "1.0.3";
9983
+ var version = "1.0.4";
9980
9984
  export {
9981
9985
  PLUGIN_CSS_NAME,
9982
9986
  PLUGIN_SWC_NAME,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rsbuild/core",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "The Rspack-based build tool.",
5
5
  "homepage": "https://rsbuild.dev",
6
6
  "bugs": {