bunup 0.8.55 → 0.8.57

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 CHANGED
@@ -14,9 +14,9 @@
14
14
 
15
15
  Bunup is the **blazing-fast build tool** for TypeScript and JavaScript libraries, designed for flawless developer experience and speed, **powered by Bun**.
16
16
 
17
- It's the fastest library bundler out there - [see benchmarks](https://gugustinette.github.io/bundler-benchmark/).
17
+ ![Bunup benchmarks](/assets/benchmarks.png)
18
18
 
19
- ![bunup-demo](/assets/demo.gif)
19
+ *The benchmark above shows build times for a project with 1,000 files, functions, and types, with TypeScript declaration generation enabled. For detailed benchmarks, visit [here](https://gugustinette.github.io/bundler-benchmark/)*
20
20
 
21
21
  </div>
22
22
  <!-- markdownlint-restore -->
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  BunupPluginError
3
- } from "./chunk-cakmscpb.js";
3
+ } from "./chunk-w9q3brxd.js";
4
4
 
5
5
  // src/plugins/utils.ts
6
6
  import pc from "picocolors";
@@ -3,7 +3,7 @@ import {
3
3
  filterBunupPlugins,
4
4
  runPluginBuildDoneHooks,
5
5
  runPluginBuildStartHooks
6
- } from "./chunk-zpjpa5th.js";
6
+ } from "./chunk-0e6rexd1.js";
7
7
  import {
8
8
  loadPackageJson
9
9
  } from "./chunk-gh7z7s46.js";
@@ -24,7 +24,7 @@ import {
24
24
  logger,
25
25
  parseErrorMessage,
26
26
  setSilent
27
- } from "./chunk-cakmscpb.js";
27
+ } from "./chunk-w9q3brxd.js";
28
28
 
29
29
  // src/build.ts
30
30
  import path from "path";
@@ -193,7 +193,7 @@ function getResolvedSplitting(splitting, format) {
193
193
  return splitting === undefined ? format === "esm" : splitting;
194
194
  }
195
195
  function getResolvedDtsSplitting(buildSplitting, dtsSplitting) {
196
- return dtsSplitting ?? buildSplitting ?? true;
196
+ return dtsSplitting ?? buildSplitting ?? false;
197
197
  }
198
198
  var DEFAULT_ENTRY_NAMING = "[dir]/[name].[ext]";
199
199
  function getResolvedNaming(fmt, packageType) {
@@ -362,8 +362,6 @@ async function build(partialOptions, rootDir = process.cwd()) {
362
362
  }
363
363
  } catch (error) {
364
364
  throw new BunupDTSBuildError(parseErrorMessage(error));
365
- } finally {
366
- logger.space();
367
365
  }
368
366
  }
369
367
  await runPluginBuildDoneHooks(bunupPlugins, options, buildOutput, {
@@ -1,11 +1,11 @@
1
1
  // @bun
2
2
  import {
3
3
  displayBunupGradientArt
4
- } from "./chunk-4cgw2ywa.js";
4
+ } from "./chunk-gyyqw66f.js";
5
5
  import {
6
6
  link,
7
7
  pathExistsSync
8
- } from "./chunk-cakmscpb.js";
8
+ } from "./chunk-w9q3brxd.js";
9
9
 
10
10
  // src/cli/new.ts
11
11
  import { renameSync } from "fs";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  logger
3
- } from "./chunk-cakmscpb.js";
3
+ } from "./chunk-w9q3brxd.js";
4
4
 
5
5
  // src/cli/utils.ts
6
6
  import pc from "picocolors";
@@ -69,7 +69,7 @@ class Logger {
69
69
  tick = false,
70
70
  type = "info"
71
71
  } = options;
72
- const icon = this.getIcon(type, tick);
72
+ const icon = options.icon ?? this.getIcon(type, tick);
73
73
  const styledMessage = muted ? pc.dim(message) : type === "error" ? pc.red(message) : type === "warn" ? pc.yellow(message) : message;
74
74
  const identifierPart = this.formatIdentifier(identifier);
75
75
  return `${icon} ${styledMessage}${identifierPart}`;
@@ -4,11 +4,11 @@ import {
4
4
  } from "./chunk-gh7z7s46.js";
5
5
  import {
6
6
  displayBunupGradientArt
7
- } from "./chunk-4cgw2ywa.js";
7
+ } from "./chunk-gyyqw66f.js";
8
8
  import {
9
9
  formatListWithAnd,
10
10
  link
11
- } from "./chunk-cakmscpb.js";
11
+ } from "./chunk-w9q3brxd.js";
12
12
 
13
13
  // src/cli/init.ts
14
14
  import fs from "fs";
package/dist/cli/index.js CHANGED
@@ -3,8 +3,8 @@
3
3
  import {
4
4
  build,
5
5
  createBuildOptions
6
- } from "../chunk-9mn5tdt7.js";
7
- import"../chunk-zpjpa5th.js";
6
+ } from "../chunk-2hchnc6a.js";
7
+ import"../chunk-0e6rexd1.js";
8
8
  import {
9
9
  processLoadedConfigs
10
10
  } from "../chunk-gh7z7s46.js";
@@ -21,14 +21,14 @@ import {
21
21
  logger,
22
22
  parseErrorMessage,
23
23
  setSilent
24
- } from "../chunk-cakmscpb.js";
24
+ } from "../chunk-w9q3brxd.js";
25
25
 
26
26
  // src/cli/index.ts
27
27
  import { loadConfig } from "coffi";
28
28
  import pc3 from "picocolors";
29
29
  import { exec } from "tinyexec";
30
30
  // package.json
31
- var version = "0.8.55";
31
+ var version = "0.8.57";
32
32
 
33
33
  // src/watch.ts
34
34
  import path from "path";
@@ -63,7 +63,9 @@ async function watch(partialOptions, rootDir) {
63
63
  const start = performance.now();
64
64
  await build(options, rootDir);
65
65
  if (!initial) {
66
- logger.success(`\uD83D\uDCE6 Rebuild finished in ${pc.green(formatTime(performance.now() - start))}`);
66
+ logger.success(`Rebuild finished in ${pc.green(formatTime(performance.now() - start))}`, {
67
+ icon: "\uD83D\uDCE6"
68
+ });
67
69
  }
68
70
  } catch (error) {
69
71
  handleError(error);
@@ -71,12 +73,7 @@ async function watch(partialOptions, rootDir) {
71
73
  isRebuilding = false;
72
74
  }
73
75
  };
74
- watcher.on("change", (filePath) => {
75
- const changedFile = path.relative(rootDir, filePath);
76
- logger.info(`File changed: ${changedFile}`, {
77
- muted: true,
78
- once: changedFile
79
- });
76
+ watcher.on("change", () => {
80
77
  triggerRebuild();
81
78
  });
82
79
  watcher.on("error", (error) => {
@@ -485,12 +482,12 @@ var parseCliOptions = (argv) => {
485
482
  async function main(args = Bun.argv.slice(2)) {
486
483
  const cliOptions = parseCliOptions(args);
487
484
  if (cliOptions.new) {
488
- const { newProject } = await import("../chunk-c4xe90dt.js");
485
+ const { newProject } = await import("../chunk-31j04536.js");
489
486
  await newProject();
490
487
  return;
491
488
  }
492
489
  if (cliOptions.init) {
493
- const { init } = await import("../chunk-p86qvgaa.js");
490
+ const { init } = await import("../chunk-whm2fp6r.js");
494
491
  await init();
495
492
  return;
496
493
  }
@@ -532,7 +529,10 @@ async function main(args = Bun.argv.slice(2)) {
532
529
  const timeDisplay = formatTime(buildTimeMs);
533
530
  logger.success(`Build completed in ${pc3.green(timeDisplay)}`);
534
531
  if (cliOptions.watch) {
535
- logger.info("Watching for file changes...");
532
+ logger.info("Watching for file changes...", {
533
+ icon: "\uD83D\uDC40",
534
+ verticalSpace: true
535
+ });
536
536
  }
537
537
  if (cliOptions.onSuccess) {
538
538
  logger.info(`Running command: ${cliOptions.onSuccess}`, {
package/dist/index.js CHANGED
@@ -1,10 +1,10 @@
1
1
  // @bun
2
2
  import {
3
3
  build
4
- } from "./chunk-9mn5tdt7.js";
5
- import"./chunk-zpjpa5th.js";
4
+ } from "./chunk-2hchnc6a.js";
5
+ import"./chunk-0e6rexd1.js";
6
6
  import"./chunk-gh7z7s46.js";
7
- import"./chunk-cakmscpb.js";
7
+ import"./chunk-w9q3brxd.js";
8
8
  // src/define.ts
9
9
  function defineConfig(options) {
10
10
  return options;
package/dist/plugins.js CHANGED
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  import {
3
3
  getPackageForPlugin
4
- } from "./chunk-zpjpa5th.js";
4
+ } from "./chunk-0e6rexd1.js";
5
5
  import {
6
6
  CSS_RE,
7
7
  JS_DTS_RE,
@@ -9,7 +9,7 @@ import {
9
9
  cleanPath,
10
10
  isDirectoryPath,
11
11
  logger
12
- } from "./chunk-cakmscpb.js";
12
+ } from "./chunk-w9q3brxd.js";
13
13
 
14
14
  // src/plugins/built-in/copy.ts
15
15
  import { basename, join } from "path";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "bunup",
3
3
  "description": "⚡ A blazing-fast build tool for your libraries built with Bun.",
4
- "version": "0.8.55",
4
+ "version": "0.8.57",
5
5
  "type": "module",
6
6
  "files": [
7
7
  "dist"
@@ -53,7 +53,7 @@
53
53
  "picocolors": "^1.1.1",
54
54
  "replace-in-file": "^8.3.0",
55
55
  "tinyexec": "^1.0.1",
56
- "typeroll": "^0.6.14"
56
+ "typeroll": "^0.6.15"
57
57
  },
58
58
  "devDependencies": {
59
59
  "@babel/types": "^7.27.7",