bunchee 6.6.0 → 6.6.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/dist/bin/cli.js +9 -10
- package/package.json +27 -24
package/dist/bin/cli.js
CHANGED
|
@@ -11,6 +11,7 @@ var index_js = require('../index.js');
|
|
|
11
11
|
require('module');
|
|
12
12
|
var fastGlob = require('fast-glob');
|
|
13
13
|
var prettyBytes = require('pretty-bytes');
|
|
14
|
+
var nanospinner = require('nanospinner');
|
|
14
15
|
|
|
15
16
|
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
16
17
|
|
|
@@ -1237,15 +1238,13 @@ async function run(args) {
|
|
|
1237
1238
|
const cliEntry = source ? path__default.default.resolve(cwd, source) : '';
|
|
1238
1239
|
// lint package by default
|
|
1239
1240
|
await lint(cwd);
|
|
1240
|
-
const
|
|
1241
|
-
const oraInstance = process.stdout.isTTY ? ora({
|
|
1242
|
-
text: 'Building...\n\n',
|
|
1241
|
+
const spinnerInstance = process.stdout.isTTY ? nanospinner.createSpinner('Building...\n\n', {
|
|
1243
1242
|
color: 'green'
|
|
1244
1243
|
}) : {
|
|
1245
1244
|
start: ()=>{},
|
|
1246
1245
|
stop: ()=>{},
|
|
1247
1246
|
clear: ()=>{},
|
|
1248
|
-
|
|
1247
|
+
success: ()=>{},
|
|
1249
1248
|
isSpinning: false
|
|
1250
1249
|
};
|
|
1251
1250
|
const spinner = {
|
|
@@ -1253,18 +1252,18 @@ async function run(args) {
|
|
|
1253
1252
|
stop: stopSpinner
|
|
1254
1253
|
};
|
|
1255
1254
|
function startSpinner() {
|
|
1256
|
-
|
|
1255
|
+
spinnerInstance.start();
|
|
1257
1256
|
}
|
|
1258
1257
|
function stopSpinner(text) {
|
|
1259
|
-
if (
|
|
1260
|
-
|
|
1258
|
+
if (spinnerInstance.isSpinning) {
|
|
1259
|
+
spinnerInstance.clear();
|
|
1261
1260
|
if (text) {
|
|
1262
|
-
|
|
1263
|
-
|
|
1261
|
+
spinnerInstance.success({
|
|
1262
|
+
mark: '✔',
|
|
1264
1263
|
text
|
|
1265
1264
|
});
|
|
1266
1265
|
} else {
|
|
1267
|
-
|
|
1266
|
+
spinnerInstance.stop();
|
|
1268
1267
|
}
|
|
1269
1268
|
}
|
|
1270
1269
|
}
|
package/package.json
CHANGED
|
@@ -1,10 +1,29 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bunchee",
|
|
3
|
-
"version": "6.6.
|
|
3
|
+
"version": "6.6.1",
|
|
4
4
|
"description": "zero config bundler for js/ts/jsx libraries",
|
|
5
5
|
"bin": "./dist/bin/cli.js",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"types": "./dist/index.d.ts",
|
|
8
|
+
"scripts": {
|
|
9
|
+
"test": "vitest run",
|
|
10
|
+
"test:update": "TEST_UPDATE_SNAPSHOT=1 pnpm test",
|
|
11
|
+
"test:post": "cross-env POST_BUILD=1 pnpm test test/compile.test.ts test/integration.test.ts",
|
|
12
|
+
"docs:dev": "next dev docs",
|
|
13
|
+
"docs:build": "next build docs",
|
|
14
|
+
"clean": "rm -rf ./dist",
|
|
15
|
+
"new-test": "node ./scripts/new-test.js",
|
|
16
|
+
"typecheck": "tsc --noEmit && tsc -p test/tsconfig.json --noEmit",
|
|
17
|
+
"prepare-release": "pnpm clean && pnpm build",
|
|
18
|
+
"publish-local": "pnpm prepare-release && pnpm test && pnpm publish",
|
|
19
|
+
"prepublishOnly": "pnpm prepare-release && chmod +x ./dist/bin/cli.js",
|
|
20
|
+
"run-ts": "cross-env SWC_NODE_IGNORE_DYNAMIC=1 node -r @swc-node/register",
|
|
21
|
+
"ts-bunchee": "pnpm run-ts ./src/bin/index.ts",
|
|
22
|
+
"build-dir": "pnpm ts-bunchee --cwd",
|
|
23
|
+
"build": "pnpm run-ts ./src/bin/index.ts --runtime node",
|
|
24
|
+
"format": "prettier --write .",
|
|
25
|
+
"prepare": "husky"
|
|
26
|
+
},
|
|
8
27
|
"type": "commonjs",
|
|
9
28
|
"keywords": [
|
|
10
29
|
"bundler",
|
|
@@ -46,15 +65,15 @@
|
|
|
46
65
|
"@swc/core": "^1.13.3",
|
|
47
66
|
"@swc/helpers": "^0.5.17",
|
|
48
67
|
"clean-css": "^5.3.3",
|
|
49
|
-
"fast-glob": "^3.3.3",
|
|
50
68
|
"magic-string": "^0.30.17",
|
|
51
|
-
"
|
|
69
|
+
"nanospinner": "^1.2.2",
|
|
52
70
|
"picomatch": "^4.0.2",
|
|
53
71
|
"pretty-bytes": "^5.6.0",
|
|
54
|
-
"rollup": "^4.
|
|
55
|
-
"rollup-plugin-dts": "^6.2.
|
|
72
|
+
"rollup": "^4.52.4",
|
|
73
|
+
"rollup-plugin-dts": "^6.2.3",
|
|
56
74
|
"rollup-plugin-swc3": "^0.11.1",
|
|
57
75
|
"rollup-preserve-directives": "^1.1.3",
|
|
76
|
+
"tinyglobby": "^0.2.14",
|
|
58
77
|
"tslib": "^2.8.1",
|
|
59
78
|
"yargs": "^17.7.2"
|
|
60
79
|
},
|
|
@@ -83,7 +102,7 @@
|
|
|
83
102
|
"cross-env": "^7.0.3",
|
|
84
103
|
"husky": "^9.0.11",
|
|
85
104
|
"lint-staged": "^15.2.2",
|
|
86
|
-
"next": "
|
|
105
|
+
"next": "16.0.0-canary.1",
|
|
87
106
|
"picocolors": "^1.0.0",
|
|
88
107
|
"postcss": "^8.5.4",
|
|
89
108
|
"prettier": "3.4.2",
|
|
@@ -96,21 +115,5 @@
|
|
|
96
115
|
"lint-staged": {
|
|
97
116
|
"*.{js,jsx,ts,tsx,md,json,yml,yaml}": "prettier --write"
|
|
98
117
|
},
|
|
99
|
-
"
|
|
100
|
-
|
|
101
|
-
"test:update": "TEST_UPDATE_SNAPSHOT=1 pnpm test",
|
|
102
|
-
"test:post": "cross-env POST_BUILD=1 pnpm test test/compile.test.ts test/integration.test.ts",
|
|
103
|
-
"docs:dev": "next dev docs",
|
|
104
|
-
"docs:build": "next build docs",
|
|
105
|
-
"clean": "rm -rf ./dist",
|
|
106
|
-
"new-test": "node ./scripts/new-test.js",
|
|
107
|
-
"typecheck": "tsc --noEmit && tsc -p test/tsconfig.json --noEmit",
|
|
108
|
-
"prepare-release": "pnpm clean && pnpm build",
|
|
109
|
-
"publish-local": "pnpm prepare-release && pnpm test && pnpm publish",
|
|
110
|
-
"run-ts": "cross-env SWC_NODE_IGNORE_DYNAMIC=1 node -r @swc-node/register",
|
|
111
|
-
"ts-bunchee": "pnpm run-ts ./src/bin/index.ts",
|
|
112
|
-
"build-dir": "pnpm ts-bunchee --cwd",
|
|
113
|
-
"build": "pnpm run-ts ./src/bin/index.ts --runtime node",
|
|
114
|
-
"format": "prettier --write ."
|
|
115
|
-
}
|
|
116
|
-
}
|
|
118
|
+
"packageManager": "pnpm@9.4.0"
|
|
119
|
+
}
|