robuild 0.1.14 → 0.1.16

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.
@@ -19,7 +19,6 @@ import { transform } from "oxc-transform";
19
19
  import { glob as glob$1 } from "tinyglobby";
20
20
  import { exec } from "node:child_process";
21
21
  import { promisify } from "node:util";
22
-
23
22
  //#region src/utils/extensions.ts
24
23
  /**
25
24
  * Get file extension for a given format (with leading dot).
@@ -96,7 +95,6 @@ function createFilename(basename, format, isDts = false, options = {}) {
96
95
  if (isDts) return `${basename}.${resolveDtsOutputExtension(format, fixedExtension)}`;
97
96
  return `${basename}.${resolveJsOutputExtension(format, platform, fixedExtension)}`;
98
97
  }
99
-
100
98
  //#endregion
101
99
  //#region src/utils/hash.ts
102
100
  /**
@@ -120,7 +118,6 @@ function addHashToFilename(filename, content, hashLength = 8) {
120
118
  function hasHash(filename) {
121
119
  return /-[a-f0-9]{8}(?:\.|$)/.test(filename);
122
120
  }
123
-
124
121
  //#endregion
125
122
  //#region src/utils/node-protocol.ts
126
123
  /**
@@ -210,7 +207,6 @@ function transformNodeProtocol(code, nodeProtocol) {
210
207
  return match.replace(moduleId, processedId);
211
208
  });
212
209
  }
213
-
214
210
  //#endregion
215
211
  //#region src/utils/index.ts
216
212
  /**
@@ -295,7 +291,6 @@ async function distSize(dir, entry) {
295
291
  async function sideEffectSize(_dir, _entry) {
296
292
  return 0;
297
293
  }
298
-
299
294
  //#endregion
300
295
  //#region src/config/entry-resolver.ts
301
296
  /**
@@ -354,7 +349,6 @@ function hasValidInput(entry) {
354
349
  if (entry.type === "transform") return !!entry.input;
355
350
  return !!getBundleEntryInput(entry);
356
351
  }
357
-
358
352
  //#endregion
359
353
  //#region src/config/external.ts
360
354
  /**
@@ -437,7 +431,6 @@ function resolveExternalConfig(ctx, options) {
437
431
  if (typeof options.external === "function") return options.external;
438
432
  return externalDeps;
439
433
  }
440
-
441
434
  //#endregion
442
435
  //#region src/features/css/index.ts
443
436
  /**
@@ -450,11 +443,10 @@ const defaultCssBundleName = "style.css";
450
443
  function resolveCssOptions(options = {}) {
451
444
  return {
452
445
  splitting: options.splitting ?? true,
453
- fileName: options.fileName ?? defaultCssBundleName,
446
+ fileName: options.fileName ?? "style.css",
454
447
  lightningcss: options.lightningcss ?? false
455
448
  };
456
449
  }
457
-
458
450
  //#endregion
459
451
  //#region src/utils/lightningcss.ts
460
452
  /**
@@ -507,7 +499,6 @@ function parseVersion(version) {
507
499
  if (Number.isNaN(major) || Number.isNaN(minor) || Number.isNaN(patch)) return null;
508
500
  return major << 16 | minor << 8 | patch;
509
501
  }
510
-
511
502
  //#endregion
512
503
  //#region src/features/css/lightningcss.ts
513
504
  /**
@@ -528,7 +519,6 @@ async function createLightningCSSPlugin(options = {}) {
528
519
  const targets = targetArray && esbuildTargetToLightningCSS(targetArray);
529
520
  return LightningCSS.default({ options: targets ? { targets } : {} });
530
521
  }
531
-
532
522
  //#endregion
533
523
  //#region src/features/css/splitting.ts
534
524
  /**
@@ -614,7 +604,74 @@ function normalizeCssFileName(cssFileName) {
614
604
  function normalizeChunkFileName(chunkFileName) {
615
605
  return chunkFileName.replace(RE_CHUNK_HASH, "").replace(RE_CHUNK_EXT, "");
616
606
  }
617
-
607
+ //#endregion
608
+ //#region src/plugins/builtin/css.ts
609
+ /**
610
+ * Built-in CSS plugin for robuild.
611
+ *
612
+ * Since rolldown 1.0.0-rc.9 removed experimental CSS bundling support,
613
+ * this plugin handles CSS files by:
614
+ * 1. Loading CSS file content as text
615
+ * 2. Collecting all CSS content
616
+ * 3. Emitting a combined CSS asset file
617
+ *
618
+ * This allows CSS imports in JS/TS files to work without rolldown errors.
619
+ */
620
+ function createBuiltinCssPlugin(options = {}) {
621
+ const { fileName = "style.css", splitting = true } = options;
622
+ const cssMap = /* @__PURE__ */ new Map();
623
+ return {
624
+ name: "robuild:css",
625
+ async load(id) {
626
+ if (!id.endsWith(".css")) return null;
627
+ try {
628
+ const content = await readFile(id, "utf-8");
629
+ cssMap.set(id, content);
630
+ } catch {
631
+ cssMap.set(id, "");
632
+ }
633
+ return {
634
+ code: "",
635
+ moduleType: "js"
636
+ };
637
+ },
638
+ generateBundle(_outputOptions, bundle) {
639
+ if (cssMap.size === 0) return;
640
+ if (splitting) {
641
+ const chunks = Object.values(bundle);
642
+ for (const chunk of chunks) {
643
+ if (chunk.type !== "chunk" || !chunk.isEntry) continue;
644
+ const chunkCss = [];
645
+ const visited = /* @__PURE__ */ new Set();
646
+ function collectCss(moduleIds) {
647
+ for (const id of moduleIds) {
648
+ if (visited.has(id)) continue;
649
+ visited.add(id);
650
+ if (cssMap.has(id)) chunkCss.push(cssMap.get(id));
651
+ }
652
+ }
653
+ collectCss(chunk.moduleIds);
654
+ if (chunkCss.length > 0) {
655
+ const cssContent = chunkCss.join("\n");
656
+ const cssFileName = chunk.fileName.replace(/\.(m?js|cjs)$/, ".css");
657
+ this.emitFile({
658
+ type: "asset",
659
+ fileName: cssFileName,
660
+ source: cssContent
661
+ });
662
+ }
663
+ }
664
+ } else {
665
+ const allCss = [...cssMap.values()].join("\n");
666
+ if (allCss.trim()) this.emitFile({
667
+ type: "asset",
668
+ fileName,
669
+ source: allCss
670
+ });
671
+ }
672
+ }
673
+ };
674
+ }
618
675
  //#endregion
619
676
  //#region src/core/logger.ts
620
677
  /**
@@ -703,7 +760,6 @@ function resetLogCounts() {
703
760
  function shouldFailOnWarnings(failOnWarn) {
704
761
  return logger.shouldFailOnWarnings(failOnWarn);
705
762
  }
706
-
707
763
  //#endregion
708
764
  //#region src/plugins/builtin/glob-import.ts
709
765
  /**
@@ -827,7 +883,6 @@ function parseGlobOptions(optionsStr) {
827
883
  function hasGlobImports(code) {
828
884
  return /import\.meta\.glob\s*\(/.test(code);
829
885
  }
830
-
831
886
  //#endregion
832
887
  //#region src/plugins/builtin/node-protocol.ts
833
888
  /**
@@ -845,7 +900,6 @@ function nodeProtocolPlugin(nodeProtocol) {
845
900
  }
846
901
  };
847
902
  }
848
-
849
903
  //#endregion
850
904
  //#region src/plugins/builtin/shebang.ts
851
905
  const SHEBANG_RE = /^#![^\n]*/;
@@ -866,7 +920,6 @@ function hasShebang(code) {
866
920
  async function makeExecutable(filePath) {
867
921
  await promises.chmod(filePath, 493).catch(() => {});
868
922
  }
869
-
870
923
  //#endregion
871
924
  //#region src/plugins/builtin/shims.ts
872
925
  /**
@@ -1012,7 +1065,6 @@ function createNodeShimsPlugin() {
1012
1065
  }
1013
1066
  };
1014
1067
  }
1015
-
1016
1068
  //#endregion
1017
1069
  //#region src/plugins/builtin/skip-node-modules.ts
1018
1070
  /**
@@ -1041,7 +1093,6 @@ function createSkipNodeModulesPlugin(options) {
1041
1093
  }
1042
1094
  };
1043
1095
  }
1044
-
1045
1096
  //#endregion
1046
1097
  //#region src/plugins/builtin/wasm.ts
1047
1098
  /**
@@ -1077,7 +1128,7 @@ function normalizeWasmConfig(config) {
1077
1128
  */
1078
1129
  async function createWasmPlugin(config) {
1079
1130
  try {
1080
- const { wasm } = await import("./dist-Dg_s5x2F.mjs");
1131
+ const { wasm } = await import("./dist-D0KplbyY.mjs");
1081
1132
  return wasm({
1082
1133
  maxFileSize: config.maxFileSize,
1083
1134
  fileName: config.fileName,
@@ -1089,7 +1140,6 @@ async function createWasmPlugin(config) {
1089
1140
  throw error;
1090
1141
  }
1091
1142
  }
1092
-
1093
1143
  //#endregion
1094
1144
  //#region src/plugins/manager.ts
1095
1145
  /**
@@ -1243,7 +1293,6 @@ var RobuildPluginManager = class {
1243
1293
  };
1244
1294
  }
1245
1295
  };
1246
-
1247
1296
  //#endregion
1248
1297
  //#region src/transforms/banner.ts
1249
1298
  /**
@@ -1277,7 +1326,6 @@ function addBannerFooter(content, banner, footer) {
1277
1326
  result = addFooter(result, footer);
1278
1327
  return result;
1279
1328
  }
1280
-
1281
1329
  //#endregion
1282
1330
  //#region src/transforms/clean.ts
1283
1331
  /**
@@ -1309,7 +1357,6 @@ async function cleanOutputDir(projectRoot, outDir, cleanPaths) {
1309
1357
  }
1310
1358
  }
1311
1359
  }
1312
-
1313
1360
  //#endregion
1314
1361
  //#region src/transforms/copy.ts
1315
1362
  /**
@@ -1334,7 +1381,6 @@ async function copyFiles(cwd, outDir, copyOptions) {
1334
1381
  }));
1335
1382
  logger.verbose("Files copied successfully");
1336
1383
  }
1337
-
1338
1384
  //#endregion
1339
1385
  //#region src/builders/bundle.ts
1340
1386
  /**
@@ -1404,6 +1450,7 @@ async function createBundleInputConfig(ctx, entry, config) {
1404
1450
  }
1405
1451
  }
1406
1452
  const cssOptions = resolveCssOptions(config?.css);
1453
+ const hasCssLoader = entry.loaders?.[".css"] !== void 0;
1407
1454
  if (cssOptions.lightningcss) {
1408
1455
  const lightningPlugin = await createLightningCSSPlugin({ target });
1409
1456
  if (lightningPlugin) rolldownPlugins.push(lightningPlugin);
@@ -1411,9 +1458,14 @@ async function createBundleInputConfig(ctx, entry, config) {
1411
1458
  logger.warn("LightningCSS is enabled but unplugin-lightningcss is not installed.");
1412
1459
  logger.warn("Install it with: pnpm add -D unplugin-lightningcss lightningcss");
1413
1460
  }
1461
+ } else if (!hasCssLoader) {
1462
+ rolldownPlugins.push(createBuiltinCssPlugin({
1463
+ fileName: cssOptions.fileName,
1464
+ splitting: cssOptions.splitting
1465
+ }));
1466
+ const cssSplitPlugin = createCssCodeSplitPlugin(cssOptions);
1467
+ if (cssSplitPlugin) rolldownPlugins.push(cssSplitPlugin);
1414
1468
  }
1415
- const cssSplitPlugin = createCssCodeSplitPlugin(cssOptions);
1416
- if (cssSplitPlugin) rolldownPlugins.push(cssSplitPlugin);
1417
1469
  rolldownPlugins.push(...pluginManager.getRolldownPlugins());
1418
1470
  const moduleTypes = {};
1419
1471
  if (entry.loaders) for (const [ext, loaderConfig] of Object.entries(entry.loaders)) moduleTypes[ext] = loaderConfig.loader;
@@ -1676,7 +1728,6 @@ function normalizeBundleInputs(input, ctx) {
1676
1728
  }
1677
1729
  return inputs;
1678
1730
  }
1679
-
1680
1731
  //#endregion
1681
1732
  //#region src/builders/unbundle.ts
1682
1733
  /**
@@ -1781,7 +1832,6 @@ function getUnbundleOutputExtension(inputExt, entry) {
1781
1832
  default: return ".js";
1782
1833
  }
1783
1834
  }
1784
-
1785
1835
  //#endregion
1786
1836
  //#region src/builders/transform.ts
1787
1837
  /**
@@ -1942,7 +1992,6 @@ async function transformModule(entryPath, entry) {
1942
1992
  if (entry.nodeProtocol) transformed.code = transformNodeProtocol(transformed.code, entry.nodeProtocol);
1943
1993
  return transformed;
1944
1994
  }
1945
-
1946
1995
  //#endregion
1947
1996
  //#region src/config/vite-config.ts
1948
1997
  /**
@@ -2081,7 +2130,6 @@ function mergeViteConfig(viteConfig, config) {
2081
2130
  ...config
2082
2131
  };
2083
2132
  }
2084
-
2085
2133
  //#endregion
2086
2134
  //#region src/transforms/exports.ts
2087
2135
  /**
@@ -2225,7 +2273,6 @@ function updatePackageJsonExports(packageRoot, exports) {
2225
2273
  throw new Error(`Failed to update package.json: ${error}`);
2226
2274
  }
2227
2275
  }
2228
-
2229
2276
  //#endregion
2230
2277
  //#region src/transforms/on-success.ts
2231
2278
  const execAsync = promisify(exec);
@@ -2262,14 +2309,13 @@ function createBuildResult(entries, startTime) {
2262
2309
  duration: Date.now() - startTime
2263
2310
  };
2264
2311
  }
2265
-
2266
2312
  //#endregion
2267
2313
  //#region src/watch.ts
2268
2314
  /**
2269
2315
  * Perform watch build using rolldown's built-in watch mode
2270
2316
  */
2271
2317
  async function performWatchBuild(config, ctx, startTime) {
2272
- const { performBuild } = await import("./build-ogb8L7fk.mjs");
2318
+ const { performBuild } = await import("./build-DlIVMHjs.mjs");
2273
2319
  await performBuild(config, ctx, startTime);
2274
2320
  const bundleEntries = (config.entries || []).filter((entry) => {
2275
2321
  if (typeof entry === "string") return !entry.endsWith("/");
@@ -2289,7 +2335,7 @@ async function performWatchBuild(config, ctx, startTime) {
2289
2335
  */
2290
2336
  async function startRolldownWatch(config, ctx, bundleEntries) {
2291
2337
  logger.info("Watching for changes...");
2292
- const { inheritConfig } = await import("./build-ogb8L7fk.mjs");
2338
+ const { inheritConfig } = await import("./build-DlIVMHjs.mjs");
2293
2339
  const watchConfigs = [];
2294
2340
  for (const rawEntry of bundleEntries) {
2295
2341
  let entry = typeof rawEntry === "string" ? parseEntryString(rawEntry) : rawEntry;
@@ -2341,7 +2387,6 @@ async function startRolldownWatch(config, ctx, bundleEntries) {
2341
2387
  process.on("SIGTERM", cleanup);
2342
2388
  return new Promise(() => {});
2343
2389
  }
2344
-
2345
2390
  //#endregion
2346
2391
  //#region src/build.ts
2347
2392
  /**
@@ -2472,6 +2517,5 @@ async function performBuild(config, ctx, startTime) {
2472
2517
  async function readJSON(specifier) {
2473
2518
  return (await import(specifier, { with: { type: "json" } })).default;
2474
2519
  }
2475
-
2476
2520
  //#endregion
2477
- export { resolveCssOptions as S, configureLogger as _, createSkipNodeModulesPlugin as a, createLightningCSSPlugin as b, createNodeShimsPlugin as c, hasShebang as d, makeExecutable as f, hasGlobImports as g, createGlobImportPlugin as h, RobuildPluginManager as i, createShimsPlugin as l, nodeProtocolPlugin as m, inheritConfig as n, DEFAULT_SHIMS_CONFIG as o, shebangPlugin as p, performBuild as r, createBrowserShimsPlugin as s, build as t, SHEBANG_RE as u, logger as v, esbuildTargetToLightningCSS as x, createCssCodeSplitPlugin as y };
2521
+ export { resolveCssOptions as C, esbuildTargetToLightningCSS as S, configureLogger as _, createSkipNodeModulesPlugin as a, createCssCodeSplitPlugin as b, createNodeShimsPlugin as c, hasShebang as d, makeExecutable as f, hasGlobImports as g, createGlobImportPlugin as h, RobuildPluginManager as i, createShimsPlugin as l, nodeProtocolPlugin as m, inheritConfig as n, DEFAULT_SHIMS_CONFIG as o, shebangPlugin as p, performBuild as r, createBrowserShimsPlugin as s, build as t, SHEBANG_RE as u, logger as v, createLightningCSSPlugin as x, createBuiltinCssPlugin as y };
@@ -0,0 +1,2 @@
1
+ import { n as inheritConfig, r as performBuild } from "./build-CKpqg1bY.mjs";
2
+ export { inheritConfig, performBuild };
@@ -2,6 +2,5 @@
2
2
  function defineConfig(config) {
3
3
  return config;
4
4
  }
5
-
6
5
  //#endregion
7
- export { defineConfig as t };
6
+ export { defineConfig as t };
@@ -3,8 +3,7 @@ import { readFile } from "node:fs/promises";
3
3
  import { createHash } from "node:crypto";
4
4
  import { Buffer } from "node:buffer";
5
5
  import { exactRegex, id, include, or } from "rolldown/filter";
6
-
7
- //#region node_modules/.pnpm/rolldown-plugin-wasm@0.2.1_rolldown@1.0.0-rc.5/node_modules/rolldown-plugin-wasm/dist/index.mjs
6
+ //#region node_modules/.pnpm/rolldown-plugin-wasm@0.2.1_rolldown@1.0.0-rc.9/node_modules/rolldown-plugin-wasm/dist/index.mjs
8
7
  const HELPERS_ID = "\0wasm-helpers.js";
9
8
  const nodeFilePath = `
10
9
  const { readFile } = process.getBuiltinModule('fs/promises')
@@ -242,6 +241,5 @@ ${isInit ? "export default " : ""}function __wasm_init(imports) {
242
241
  }
243
242
  };
244
243
  }
245
-
246
244
  //#endregion
247
- export { wasm };
245
+ export { wasm };
@@ -2,7 +2,7 @@
2
2
  var package_default = {
3
3
  name: "robuild",
4
4
  type: "module",
5
- version: "0.1.14",
5
+ version: "0.1.16",
6
6
  packageManager: "pnpm@10.11.1",
7
7
  description: "Zero-config ESM/TS package builder. Powered by Rolldown and Oxc",
8
8
  license: "MIT",
@@ -43,8 +43,8 @@ var package_default = {
43
43
  "prepare": "husky"
44
44
  },
45
45
  dependencies: {
46
- "c12": "4.0.0-beta.3",
47
- "cac": "^6.7.14",
46
+ "c12": "4.0.0-beta.4",
47
+ "cac": "^7.0.0",
48
48
  "chokidar": "^5.0.0",
49
49
  "consola": "^3.4.2",
50
50
  "exsolve": "^1.0.8",
@@ -52,36 +52,36 @@ var package_default = {
52
52
  "jiti": "^2.6.1",
53
53
  "js-yaml": "^4.1.1",
54
54
  "magic-string": "^0.30.21",
55
- "minimatch": "^10.2.2",
56
- "oxc-minify": "^0.114.0",
57
- "oxc-parser": "^0.114.0",
58
- "oxc-transform": "^0.114.0",
55
+ "minimatch": "^10.2.4",
56
+ "oxc-minify": "^0.119.0",
57
+ "oxc-parser": "^0.119.0",
58
+ "oxc-transform": "^0.119.0",
59
59
  "pretty-bytes": "^7.1.0",
60
- "rolldown": "1.0.0-rc.5",
61
- "rolldown-plugin-dts": "^0.22.1",
60
+ "rolldown": "1.0.0-rc.9",
61
+ "rolldown-plugin-dts": "^0.22.5",
62
62
  "tinyglobby": "^0.2.15",
63
63
  "typescript": "^5.9.3"
64
64
  },
65
65
  devDependencies: {
66
66
  "@types/js-yaml": "^4.0.9",
67
- "@types/node": "^25.3.0",
68
- "@vitest/coverage-v8": "^4.0.18",
67
+ "@types/node": "^25.5.0",
68
+ "@vitest/coverage-v8": "^4.1.0",
69
69
  "automd": "^0.4.3",
70
70
  "changelogen": "^0.6.2",
71
71
  "esno": "^4.8.0",
72
72
  "git-cz": "^4.9.0",
73
73
  "husky": "^9.1.7",
74
- "lightningcss": "^1.31.1",
75
- "lint-staged": "^16.2.7",
76
- "oxlint": "^1.49.0",
74
+ "lightningcss": "^1.32.0",
75
+ "lint-staged": "^16.4.0",
76
+ "oxlint": "^1.55.0",
77
77
  "rolldown-plugin-wasm": "^0.2.1",
78
- "turbo": "^2.8.10",
78
+ "turbo": "^2.8.17",
79
79
  "unplugin-lightningcss": "^0.4.5",
80
+ "vite": "^6.0.0",
80
81
  "vitepress": "^1.6.4",
81
82
  "vitepress-plugin-group-icons": "^1.7.1",
82
- "vitest": "^4.0.18"
83
+ "vitest": "^4.1.0"
83
84
  }
84
85
  };
85
-
86
86
  //#endregion
87
- export { package_default as default };
87
+ export { package_default as default };
package/dist/cli.mjs CHANGED
@@ -1,11 +1,10 @@
1
1
  #!/usr/bin/env node
2
- import { _ as configureLogger, t as build, v as logger } from "./_chunks/build-B3vdIgJO.mjs";
2
+ import { _ as configureLogger, t as build, v as logger } from "./_chunks/build-CKpqg1bY.mjs";
3
3
  import module from "node:module";
4
4
  import { colors } from "consola/utils";
5
5
  import process from "node:process";
6
6
  import { loadConfig } from "c12";
7
7
  import { cac } from "cac";
8
-
9
8
  //#region src/cli.ts
10
9
  try {
11
10
  module.enableCompileCache?.();
@@ -137,6 +136,5 @@ try {
137
136
  logger.error(String(error));
138
137
  process.exit(1);
139
138
  }
140
-
141
139
  //#endregion
142
- export { };
140
+ export {};
package/dist/config.mjs CHANGED
@@ -1,3 +1,2 @@
1
- import { t as defineConfig } from "./_chunks/config-BGTiuDLt.mjs";
2
-
3
- export { defineConfig };
1
+ import { t as defineConfig } from "./_chunks/config-DnVMMWOP.mjs";
2
+ export { defineConfig };
package/dist/index.d.mts CHANGED
@@ -242,6 +242,31 @@ declare function createLightningCSSPlugin(options?: LightningCSSPluginOptions):
242
242
  */
243
243
  declare function createCssCodeSplitPlugin(config: Pick<Required<CssOptions>, 'splitting' | 'fileName'>): Plugin | undefined;
244
244
  //#endregion
245
+ //#region src/plugins/builtin/css.d.ts
246
+ /**
247
+ * Built-in CSS plugin for robuild.
248
+ *
249
+ * Since rolldown 1.0.0-rc.9 removed experimental CSS bundling support,
250
+ * this plugin handles CSS files by:
251
+ * 1. Loading CSS file content as text
252
+ * 2. Collecting all CSS content
253
+ * 3. Emitting a combined CSS asset file
254
+ *
255
+ * This allows CSS imports in JS/TS files to work without rolldown errors.
256
+ */
257
+ declare function createBuiltinCssPlugin(options?: {
258
+ /**
259
+ * Output CSS file name (when splitting is disabled)
260
+ * @default 'style.css'
261
+ */
262
+ fileName?: string;
263
+ /**
264
+ * Enable CSS code splitting (each entry gets its own CSS file)
265
+ * @default true
266
+ */
267
+ splitting?: boolean;
268
+ }): Plugin;
269
+ //#endregion
245
270
  //#region src/utils/lightningcss.d.ts
246
271
  /**
247
272
  * Converts esbuild target (which is also used by Rolldown) to Lightning CSS targets.
@@ -255,4 +280,4 @@ declare function createCssCodeSplitPlugin(config: Pick<Required<CssOptions>, 'sp
255
280
  */
256
281
  declare function esbuildTargetToLightningCSS(target: string[]): Targets | undefined;
257
282
  //#endregion
258
- export { type BuildConfig, type BuildEntry, type BundleEntry, type CssOptions, DEFAULT_LOADERS, DEFAULT_SHIMS_CONFIG, type ExportsConfig, type LightningCSSPluginOptions, type RobuildPlugin, RobuildPluginManager, SHEBANG_RE, type TransformEntry, build, combinePlugins, createBrowserShimsPlugin, createCjsDefaultPlugin, createCssCodeSplitPlugin, createGlobImportPlugin, createLightningCSSPlugin, createLoadPlugin, createLoaderPlugin, createNodeShimsPlugin, createPluginFactory, createResolvePlugin, createRobuildPlugin, createShimsPlugin, createSkipNodeModulesPlugin, createTransformPlugin, defineConfig, esbuildTargetToLightningCSS, extendRolldownPlugin, getLoaderForFile, hasGlobImports, hasShebang, makeExecutable, nodePolyfillsPlugin, nodeProtocolPlugin, resolveCssOptions, shebangPlugin, textPlugin, urlPlugin, virtualPlugin };
283
+ export { type BuildConfig, type BuildEntry, type BundleEntry, type CssOptions, DEFAULT_LOADERS, DEFAULT_SHIMS_CONFIG, type ExportsConfig, type LightningCSSPluginOptions, type RobuildPlugin, RobuildPluginManager, SHEBANG_RE, type TransformEntry, build, combinePlugins, createBrowserShimsPlugin, createBuiltinCssPlugin, createCjsDefaultPlugin, createCssCodeSplitPlugin, createGlobImportPlugin, createLightningCSSPlugin, createLoadPlugin, createLoaderPlugin, createNodeShimsPlugin, createPluginFactory, createResolvePlugin, createRobuildPlugin, createShimsPlugin, createSkipNodeModulesPlugin, createTransformPlugin, defineConfig, esbuildTargetToLightningCSS, extendRolldownPlugin, getLoaderForFile, hasGlobImports, hasShebang, makeExecutable, nodePolyfillsPlugin, nodeProtocolPlugin, resolveCssOptions, shebangPlugin, textPlugin, urlPlugin, virtualPlugin };
package/dist/index.mjs CHANGED
@@ -1,8 +1,7 @@
1
- import { S as resolveCssOptions, a as createSkipNodeModulesPlugin, b as createLightningCSSPlugin, c as createNodeShimsPlugin, d as hasShebang, f as makeExecutable, g as hasGlobImports, h as createGlobImportPlugin, i as RobuildPluginManager, l as createShimsPlugin, m as nodeProtocolPlugin, o as DEFAULT_SHIMS_CONFIG, p as shebangPlugin, s as createBrowserShimsPlugin, t as build, u as SHEBANG_RE, v as logger, x as esbuildTargetToLightningCSS, y as createCssCodeSplitPlugin } from "./_chunks/build-B3vdIgJO.mjs";
2
- import { t as defineConfig } from "./_chunks/config-BGTiuDLt.mjs";
1
+ import { C as resolveCssOptions, S as esbuildTargetToLightningCSS, a as createSkipNodeModulesPlugin, b as createCssCodeSplitPlugin, c as createNodeShimsPlugin, d as hasShebang, f as makeExecutable, g as hasGlobImports, h as createGlobImportPlugin, i as RobuildPluginManager, l as createShimsPlugin, m as nodeProtocolPlugin, o as DEFAULT_SHIMS_CONFIG, p as shebangPlugin, s as createBrowserShimsPlugin, t as build, u as SHEBANG_RE, v as logger, x as createLightningCSSPlugin, y as createBuiltinCssPlugin } from "./_chunks/build-CKpqg1bY.mjs";
2
+ import { t as defineConfig } from "./_chunks/config-DnVMMWOP.mjs";
3
3
  import { extname } from "node:path";
4
4
  import { readFile } from "node:fs/promises";
5
-
6
5
  //#region src/plugins/builtin/cjs-default.ts
7
6
  /**
8
7
  * Detect if a file uses CommonJS exports
@@ -55,7 +54,6 @@ function createCjsDefaultPlugin(mode = "auto") {
55
54
  }
56
55
  };
57
56
  }
58
-
59
57
  //#endregion
60
58
  //#region src/plugins/builtin/loaders.ts
61
59
  /**
@@ -237,7 +235,6 @@ function createLoaderPlugin(loaders) {
237
235
  }
238
236
  };
239
237
  }
240
-
241
238
  //#endregion
242
239
  //#region src/plugins/extras/node-polyfills.ts
243
240
  /**
@@ -263,7 +260,6 @@ function nodePolyfillsPlugin() {
263
260
  }
264
261
  };
265
262
  }
266
-
267
263
  //#endregion
268
264
  //#region src/plugins/extras/text.ts
269
265
  /**
@@ -285,7 +281,6 @@ function textPlugin(extensions = [".txt", ".md"]) {
285
281
  }
286
282
  };
287
283
  }
288
-
289
284
  //#endregion
290
285
  //#region src/plugins/extras/url.ts
291
286
  /**
@@ -310,7 +305,6 @@ function urlPlugin(extensions = [
310
305
  }
311
306
  };
312
307
  }
313
-
314
308
  //#endregion
315
309
  //#region src/plugins/extras/virtual.ts
316
310
  /**
@@ -329,7 +323,6 @@ function virtualPlugin(modules) {
329
323
  }
330
324
  };
331
325
  }
332
-
333
326
  //#endregion
334
327
  //#region src/plugins/factory.ts
335
328
  /**
@@ -483,6 +476,5 @@ function combinePlugins(name, plugins) {
483
476
  }
484
477
  return combinedPlugin;
485
478
  }
486
-
487
479
  //#endregion
488
- export { DEFAULT_LOADERS, DEFAULT_SHIMS_CONFIG, RobuildPluginManager, SHEBANG_RE, build, combinePlugins, createBrowserShimsPlugin, createCjsDefaultPlugin, createCssCodeSplitPlugin, createGlobImportPlugin, createLightningCSSPlugin, createLoadPlugin, createLoaderPlugin, createNodeShimsPlugin, createPluginFactory, createResolvePlugin, createRobuildPlugin, createShimsPlugin, createSkipNodeModulesPlugin, createTransformPlugin, defineConfig, esbuildTargetToLightningCSS, extendRolldownPlugin, getLoaderForFile, hasGlobImports, hasShebang, makeExecutable, nodePolyfillsPlugin, nodeProtocolPlugin, resolveCssOptions, shebangPlugin, textPlugin, urlPlugin, virtualPlugin };
480
+ export { DEFAULT_LOADERS, DEFAULT_SHIMS_CONFIG, RobuildPluginManager, SHEBANG_RE, build, combinePlugins, createBrowserShimsPlugin, createBuiltinCssPlugin, createCjsDefaultPlugin, createCssCodeSplitPlugin, createGlobImportPlugin, createLightningCSSPlugin, createLoadPlugin, createLoaderPlugin, createNodeShimsPlugin, createPluginFactory, createResolvePlugin, createRobuildPlugin, createShimsPlugin, createSkipNodeModulesPlugin, createTransformPlugin, defineConfig, esbuildTargetToLightningCSS, extendRolldownPlugin, getLoaderForFile, hasGlobImports, hasShebang, makeExecutable, nodePolyfillsPlugin, nodeProtocolPlugin, resolveCssOptions, shebangPlugin, textPlugin, urlPlugin, virtualPlugin };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "robuild",
3
3
  "type": "module",
4
- "version": "0.1.14",
4
+ "version": "0.1.16",
5
5
  "packageManager": "pnpm@10.11.1",
6
6
  "description": "Zero-config ESM/TS package builder. Powered by Rolldown and Oxc",
7
7
  "license": "MIT",
@@ -44,8 +44,8 @@
44
44
  "prepare": "husky"
45
45
  },
46
46
  "dependencies": {
47
- "c12": "4.0.0-beta.3",
48
- "cac": "^6.7.14",
47
+ "c12": "4.0.0-beta.4",
48
+ "cac": "^7.0.0",
49
49
  "chokidar": "^5.0.0",
50
50
  "consola": "^3.4.2",
51
51
  "exsolve": "^1.0.8",
@@ -53,33 +53,34 @@
53
53
  "jiti": "^2.6.1",
54
54
  "js-yaml": "^4.1.1",
55
55
  "magic-string": "^0.30.21",
56
- "minimatch": "^10.2.2",
57
- "oxc-minify": "^0.114.0",
58
- "oxc-parser": "^0.114.0",
59
- "oxc-transform": "^0.114.0",
56
+ "minimatch": "^10.2.4",
57
+ "oxc-minify": "^0.119.0",
58
+ "oxc-parser": "^0.119.0",
59
+ "oxc-transform": "^0.119.0",
60
60
  "pretty-bytes": "^7.1.0",
61
- "rolldown": "1.0.0-rc.5",
62
- "rolldown-plugin-dts": "^0.22.1",
61
+ "rolldown": "1.0.0-rc.9",
62
+ "rolldown-plugin-dts": "^0.22.5",
63
63
  "tinyglobby": "^0.2.15",
64
64
  "typescript": "^5.9.3"
65
65
  },
66
66
  "devDependencies": {
67
67
  "@types/js-yaml": "^4.0.9",
68
- "@types/node": "^25.3.0",
69
- "@vitest/coverage-v8": "^4.0.18",
68
+ "@types/node": "^25.5.0",
69
+ "@vitest/coverage-v8": "^4.1.0",
70
70
  "automd": "^0.4.3",
71
71
  "changelogen": "^0.6.2",
72
72
  "esno": "^4.8.0",
73
73
  "git-cz": "^4.9.0",
74
74
  "husky": "^9.1.7",
75
- "lightningcss": "^1.31.1",
76
- "lint-staged": "^16.2.7",
77
- "oxlint": "^1.49.0",
75
+ "lightningcss": "^1.32.0",
76
+ "lint-staged": "^16.4.0",
77
+ "oxlint": "^1.55.0",
78
78
  "rolldown-plugin-wasm": "^0.2.1",
79
- "turbo": "^2.8.10",
79
+ "turbo": "^2.8.17",
80
80
  "unplugin-lightningcss": "^0.4.5",
81
+ "vite": "^6.0.0",
81
82
  "vitepress": "^1.6.4",
82
83
  "vitepress-plugin-group-icons": "^1.7.1",
83
- "vitest": "^4.0.18"
84
+ "vitest": "^4.1.0"
84
85
  }
85
86
  }
@@ -1,3 +0,0 @@
1
- import { n as inheritConfig, r as performBuild, t as build } from "./build-B3vdIgJO.mjs";
2
-
3
- export { inheritConfig, performBuild };