Skip to content

Commit d65b3f7

Browse files
committed
build!: esm-only
1 parent 1aba9fb commit d65b3f7

3 files changed

Lines changed: 499 additions & 1196 deletions

File tree

‎build.config.mjs‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import { defineBuildConfig } from "obuild/config";
2+
3+
export default defineBuildConfig({
4+
entries: [
5+
{
6+
type: "bundle",
7+
input: ["./src/index.ts"],
8+
},
9+
],
10+
});

‎package.json‎

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,18 +9,12 @@
99
],
1010
"type": "module",
1111
"sideEffects": false,
12-
"main": "./dist/index.cjs",
13-
"module": "./dist/index.mjs",
14-
"types": "./dist/index.d.ts",
12+
"types": "./dist/index.d.mts",
1513
"exports": {
16-
".": {
17-
"types": "./dist/index.d.ts",
18-
"import": "./dist/index.mjs",
19-
"require": "./dist/index.cjs"
20-
}
14+
".": "./dist/index.mjs"
2115
},
2216
"scripts": {
23-
"build": "unbuild",
17+
"build": "obuild",
2418
"dev": "vitest",
2519
"lint": "oxlint . && oxfmt --check",
2620
"fmt": "oxlint . --fix && oxfmt",
@@ -44,6 +38,7 @@
4438
"concat-stream": "^2.0.0",
4539
"eslint-config-unjs": "^0.6.2",
4640
"expect.js": "^0.3.1",
41+
"obuild": "^0.4.32",
4742
"ofetch": "^1.5.1",
4843
"oxfmt": "^0.42.0",
4944
"oxlint": "^1.57.0",
@@ -52,7 +47,6 @@
5247
"socket.io-client": "^4.8.3",
5348
"sse": "^0.0.8",
5449
"typescript": "^6.0.2",
55-
"unbuild": "^3.6.1",
5650
"undici": "^7.24.6",
5751
"vitest": "^4.1.1",
5852
"ws": "^8.20.0"

0 commit comments

Comments
 (0)