Skip to content

Commit dbbc215

Browse files
committed
added exports
1 parent 160aa14 commit dbbc215

File tree

4 files changed

+15
-46
lines changed

4 files changed

+15
-46
lines changed

build.js

Lines changed: 0 additions & 20 deletions
This file was deleted.

package.json

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,20 +6,11 @@
66
},
77
"version": "0.0.33",
88
"description": "A client library to power your applications with Cloudways API",
9-
"exports": {
10-
"./core": {
11-
"require": "./dist/core/index.js",
12-
"import": "./dist/core/index.mjs",
13-
"types": "./dist/core/index.d.ts"
14-
},
15-
"./lists": {
16-
"require": "./dist/lists/index.js",
17-
"import": "./dist/lists/index.mjs",
18-
"types": "./dist/lists/index.d.ts"
19-
}
20-
},
9+
"main": "dist/index.js",
10+
"module": "dist/index.mjs",
11+
"types": "dist/index.d.ts",
2112
"scripts": {
22-
"build": "node build.js",
13+
"build": "tsup index.ts --format cjs,esm --dts",
2314
"release": "npm run build && changeset publish",
2415
"lint": "tsc"
2516
},

services/index.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
export * from "./Lists";
2+
export * from "./core";
3+
export * from "./projects";

tsconfig.json

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4,23 +4,18 @@
44
"esModuleInterop": true,
55
"skipLibCheck": true,
66
"target": "es2022",
7+
"verbatimModuleSyntax": true,
78
"allowJs": true,
89
"resolveJsonModule": true,
10+
"moduleDetection": "force",
911
/* Strictness */
1012
"strict": true,
1113
"noUncheckedIndexedAccess": true,
12-
/* Module Resolution */
13-
"moduleResolution": "node", // Adjust this to "node"
14-
"module": "commonjs", // And this to "commonjs" if you're targeting a Node environment
14+
/* If NOT transpiling with TypeScript: */
15+
"moduleResolution": "Bundler",
16+
"module": "ESNext",
1517
"noEmit": true,
16-
/* Include DOM libraries only if your environment has a DOM */
18+
/* If your code runs in the DOM: */
1719
"lib": ["es2022", "dom", "dom.iterable"],
18-
},
19-
"include": [
20-
"src/**/*" // Adjust to include the directory of your source files
21-
],
22-
"exclude": [
23-
"node_modules",
24-
"dist" // Exclude dist if you don't want TypeScript to type-check files in dist
25-
]
26-
}
20+
}
21+
}

0 commit comments

Comments
 (0)