bunup 0.9.0 → 0.9.1
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 +10 -13
- package/dist/cli/index.js +6 -6
- package/dist/index.d.ts +1 -1
- package/dist/index.js +3 -3
- package/dist/plugins.d.ts +1 -1
- package/dist/plugins.js +2 -2
- package/dist/shared/{chunk-29mdzdnt.js → chunk-b17s55p9.js} +1 -1
- package/dist/shared/{chunk-388r1g46.js → chunk-f8vey9gb.js} +4 -4
- package/dist/shared/{chunk-ge1jevhp.js → chunk-g6c05fxa.js} +1 -1
- package/dist/shared/{chunk-cdrh2sea.js → chunk-j0x1xdhb.js} +2 -2
- package/dist/shared/{chunk-gc7rjej4.js → chunk-s6wnc2s1.js} +2 -2
- package/dist/shared/{chunk-hb0esw52.js → chunk-sfjfqxjy.js} +9 -2
- package/package.json +3 -3
- /package/dist/shared/{chunk-95p7cdc9.d.ts → chunk-25dcyfg9.d.ts} +0 -0
package/README.md
CHANGED
|
@@ -10,27 +10,24 @@
|
|
|
10
10
|
|
|
11
11
|

|
|
12
12
|
|
|
13
|
-
[](https://npmjs.com/package/bunup) [](https://bun.sh) [](https://github.com/sponsors/arshad-yaseen)
|
|
14
14
|
|
|
15
15
|
Bunup is the **blazing-fast build tool** for TypeScript libraries, designed for flawless developer experience and speed, **powered by Bun**.
|
|
16
16
|
|
|
17
|
-

|
|
18
|
-
|
|
19
|
-
*For detailed information on the benchmark, visit [here](https://gugustinette.github.io/bundler-benchmark/)*
|
|
20
|
-
|
|
21
17
|
</div>
|
|
22
18
|
<!-- markdownlint-restore -->
|
|
23
19
|
|
|
24
|
-
##
|
|
20
|
+
## Features
|
|
25
21
|
|
|
26
|
-
- ⚡ **Blazing Fast**: Lightning-
|
|
27
|
-
- 📝 **
|
|
22
|
+
- ⚡ **Blazing Fast**: Lightning-fast builds and instant rebuilds.
|
|
23
|
+
- 📝 **Top-Notch TypeScript Declarations**: Clean, minimal, accurate `.d.ts` files generated automatically.
|
|
28
24
|
- 📦 **ESM by Default**: Modern ESM output by default.
|
|
29
|
-
- 🪓 **Declaration Splitting**:
|
|
30
|
-
-
|
|
31
|
-
-
|
|
32
|
-
-
|
|
33
|
-
-
|
|
25
|
+
- 🪓 **Declaration Splitting**: Splits shared types for smaller, cleaner declaration bundles.
|
|
26
|
+
- 🔥 **Declaration Minification**: Aggressively minifies and shortens type names while preserving public API—like code bundling for TypeScript declarations.
|
|
27
|
+
- 🔋 **Batteries Included**: Auto-generates package exports, detects unused dependencies and exports, and more.
|
|
28
|
+
- 🚀 **Zero-Config Simplicity**: Preconfigured for productivity—just code and build.
|
|
29
|
+
- 🏗️ **[Workspace](https://bunup.dev/docs/guide/workspaces) Ready**: Builds multiple packages from one config and command.
|
|
30
|
+
- 🔄 **Tsup Familiarity**: Familiar CLI and config for easy migration from tsup.
|
|
34
31
|
|
|
35
32
|
## 📚 Documentation
|
|
36
33
|
|
package/dist/cli/index.js
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
import {
|
|
4
4
|
build,
|
|
5
5
|
createBuildOptions
|
|
6
|
-
} from "../shared/chunk-
|
|
7
|
-
import"../shared/chunk-
|
|
6
|
+
} from "../shared/chunk-f8vey9gb.js";
|
|
7
|
+
import"../shared/chunk-g6c05fxa.js";
|
|
8
8
|
import {
|
|
9
9
|
processLoadedConfigs
|
|
10
10
|
} from "../shared/chunk-295440tx.js";
|
|
@@ -21,14 +21,14 @@ import {
|
|
|
21
21
|
logger,
|
|
22
22
|
parseErrorMessage,
|
|
23
23
|
setSilent
|
|
24
|
-
} from "../shared/chunk-
|
|
24
|
+
} from "../shared/chunk-sfjfqxjy.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.9.
|
|
31
|
+
var version = "0.9.1";
|
|
32
32
|
|
|
33
33
|
// src/watch.ts
|
|
34
34
|
import path from "path";
|
|
@@ -482,12 +482,12 @@ var parseCliOptions = (argv) => {
|
|
|
482
482
|
async function main(args = Bun.argv.slice(2)) {
|
|
483
483
|
const cliOptions = parseCliOptions(args);
|
|
484
484
|
if (cliOptions.new) {
|
|
485
|
-
const { newProject } = await import("../shared/chunk-
|
|
485
|
+
const { newProject } = await import("../shared/chunk-j0x1xdhb.js");
|
|
486
486
|
await newProject();
|
|
487
487
|
return;
|
|
488
488
|
}
|
|
489
489
|
if (cliOptions.init) {
|
|
490
|
-
const { init } = await import("../shared/chunk-
|
|
490
|
+
const { init } = await import("../shared/chunk-s6wnc2s1.js");
|
|
491
491
|
await init();
|
|
492
492
|
return;
|
|
493
493
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Arrayable, BuildOptions, DefineConfigItem, DefineWorkspaceItem, Plugin, WithOptional } from "./shared/chunk-
|
|
1
|
+
import { Arrayable, BuildOptions, DefineConfigItem, DefineWorkspaceItem, Plugin, WithOptional } from "./shared/chunk-25dcyfg9";
|
|
2
2
|
declare function build(partialOptions: Partial<BuildOptions>, rootDir?: string): Promise<void>;
|
|
3
3
|
declare function defineConfig(options: Arrayable<DefineConfigItem>): Arrayable<DefineConfigItem>;
|
|
4
4
|
declare function defineWorkspace(options: WithOptional<DefineWorkspaceItem, "config">[], sharedOptions?: DefineConfigItem): DefineWorkspaceItem[];
|
package/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
build
|
|
4
|
-
} from "./shared/chunk-
|
|
5
|
-
import"./shared/chunk-
|
|
4
|
+
} from "./shared/chunk-f8vey9gb.js";
|
|
5
|
+
import"./shared/chunk-g6c05fxa.js";
|
|
6
6
|
import"./shared/chunk-295440tx.js";
|
|
7
|
-
import"./shared/chunk-
|
|
7
|
+
import"./shared/chunk-sfjfqxjy.js";
|
|
8
8
|
// src/define.ts
|
|
9
9
|
function defineConfig(options) {
|
|
10
10
|
return options;
|
package/dist/plugins.d.ts
CHANGED
package/dist/plugins.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
getPackageForPlugin
|
|
4
|
-
} from "./shared/chunk-
|
|
4
|
+
} from "./shared/chunk-g6c05fxa.js";
|
|
5
5
|
import {
|
|
6
6
|
CSS_RE,
|
|
7
7
|
JS_DTS_RE,
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
formatListWithAnd,
|
|
11
11
|
isDirectoryPath,
|
|
12
12
|
logger
|
|
13
|
-
} from "./shared/chunk-
|
|
13
|
+
} from "./shared/chunk-sfjfqxjy.js";
|
|
14
14
|
|
|
15
15
|
// src/plugins/built-in/copy.ts
|
|
16
16
|
import { basename, join } from "path";
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
filterBunupPlugins,
|
|
4
4
|
runPluginBuildDoneHooks,
|
|
5
5
|
runPluginBuildStartHooks
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-g6c05fxa.js";
|
|
7
7
|
import {
|
|
8
8
|
loadPackageJson
|
|
9
9
|
} from "./chunk-295440tx.js";
|
|
@@ -25,7 +25,7 @@ import {
|
|
|
25
25
|
parseErrorMessage,
|
|
26
26
|
setSilent,
|
|
27
27
|
silent
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-sfjfqxjy.js";
|
|
29
29
|
|
|
30
30
|
// src/build.ts
|
|
31
31
|
import path from "path";
|
|
@@ -165,8 +165,8 @@ function getResolvedDefine(define, env) {
|
|
|
165
165
|
function getResolvedSplitting(splitting, format) {
|
|
166
166
|
return splitting === undefined ? format === "esm" : splitting;
|
|
167
167
|
}
|
|
168
|
-
function getResolvedDtsSplitting(
|
|
169
|
-
return dtsSplitting
|
|
168
|
+
function getResolvedDtsSplitting(_buildSplitting, dtsSplitting) {
|
|
169
|
+
return !!dtsSplitting;
|
|
170
170
|
}
|
|
171
171
|
var DEFAULT_ENTRY_NAMING = "[dir]/[name].[ext]";
|
|
172
172
|
function getDefaultChunkNaming(name) {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
displayBunupGradientArt
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-b17s55p9.js";
|
|
5
5
|
import {
|
|
6
6
|
link,
|
|
7
7
|
pathExistsSync
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-sfjfqxjy.js";
|
|
9
9
|
|
|
10
10
|
// src/cli/new.ts
|
|
11
11
|
import { renameSync } from "fs";
|
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
} from "./chunk-295440tx.js";
|
|
5
5
|
import {
|
|
6
6
|
displayBunupGradientArt
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-b17s55p9.js";
|
|
8
8
|
import {
|
|
9
9
|
formatListWithAnd,
|
|
10
10
|
link
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-sfjfqxjy.js";
|
|
12
12
|
|
|
13
13
|
// src/cli/init.ts
|
|
14
14
|
import fs from "fs";
|
|
@@ -220,8 +220,15 @@ var KNOWN_ERRORS = [
|
|
|
220
220
|
pattern: /Could not resolve: "bun"/i,
|
|
221
221
|
errorType: "BUILD ERROR",
|
|
222
222
|
logSolution: () => {
|
|
223
|
-
logger.
|
|
224
|
-
`
|
|
223
|
+
logger.log("You're trying to build a project that uses Bun. " + "Please set the target option to " + pc2.cyan("`bun`") + `.
|
|
224
|
+
` + "Example: " + pc2.green("`bunup --target bun`") + " or in config: " + pc2.green("{ target: 'bun' }"));
|
|
225
|
+
}
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
pattern: /has already been exported. Exported identifiers must be unique./i,
|
|
229
|
+
errorType: "DTS ERROR",
|
|
230
|
+
logSolution: () => {
|
|
231
|
+
logger.log("An error occurred while bundling dts files. This issue occurs when dts splitting is enabled due to a bug in the Bun bundler. Please ping the GitHub issue to help get it fixed faster: " + link("https://github.com/oven-sh/bun/issues/5344") + ". To fix this issue for now, you can disable dts splitting by removing " + pc2.gray("dts: { splitting: true }") + " from your config." + " You can re-enable it once the issue is fixed.");
|
|
225
232
|
}
|
|
226
233
|
}
|
|
227
234
|
];
|
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.9.
|
|
4
|
+
"version": "0.9.1",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|
|
7
7
|
"dist"
|
|
@@ -57,10 +57,10 @@
|
|
|
57
57
|
"typeroll": "^0.6.21"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
60
|
-
"@babel/types": "^7.28.
|
|
60
|
+
"@babel/types": "^7.28.2",
|
|
61
61
|
"@biomejs/biome": "2.0.0",
|
|
62
62
|
"@types/bun": "^1.2.19",
|
|
63
|
-
"bumpp": "^10.2.
|
|
63
|
+
"bumpp": "^10.2.1",
|
|
64
64
|
"husky": "^9.1.7",
|
|
65
65
|
"lightningcss": "^1.30.1",
|
|
66
66
|
"lint-staged": "^15.5.2",
|
|
File without changes
|