Skip to content

Commit 615fe43

Browse files
committed
chore: switch to tsup
1 parent cd277e2 commit 615fe43

File tree

6 files changed

+398
-398
lines changed

6 files changed

+398
-398
lines changed

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ This is a shorthand for running the following scripts in order:
2020

2121
## Good to know
2222

23-
- The project is being built by [esbuild](https://esbuild.github.io) (see [bundle.ts](scripts/bundle.ts))
23+
- The project is being built by [tsup](https://tsup.egoist.dev) (see [tsup.config.ts](tsup.config.ts))
2424
- The documentation is running via VitePress.
2525
Make sure you **build** the project before running the docs, cause some files depend on `dist`.
2626
Use `pnpm run docs:dev` to edit them in live mode.
@@ -49,7 +49,7 @@ If you change more than 20 locale files, please consider splitting your PR into
4949

5050
## Building Faker
5151

52-
The project is being built by [esbuild](https://esbuild.github.io) (see [bundle.ts](scripts/bundle.ts))
52+
The project is being built by [tsup](https://tsup.egoist.dev) (see [tsup.config.ts](tsup.config.ts))
5353

5454
```shell
5555
pnpm install

package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@
2828
],
2929
"bugs": "https://github.com/faker-js/faker/issues",
3030
"license": "MIT",
31-
"main": "dist/cjs/index.js",
32-
"module": "dist/esm/index.mjs",
31+
"main": "dist/index.js",
32+
"module": "dist/index.mjs",
3333
"types": "index.d.ts",
3434
"typesVersions": {
3535
">=4.0": {
@@ -41,13 +41,13 @@
4141
"exports": {
4242
".": {
4343
"types": "./dist/types/index.d.ts",
44-
"require": "./dist/cjs/index.js",
45-
"import": "./dist/esm/index.mjs"
44+
"require": "./dist/index.js",
45+
"import": "./dist/index.mjs"
4646
},
4747
"./locale/*": {
4848
"types": "./dist/types/locale/*.d.ts",
49-
"require": "./dist/cjs/locale/*.js",
50-
"import": "./dist/esm/locale/*.mjs"
49+
"require": "./dist/locale/*.js",
50+
"import": "./dist/locale/*.mjs"
5151
},
5252
"./package.json": "./package.json"
5353
},
@@ -58,7 +58,7 @@
5858
"scripts": {
5959
"clean": "rimraf coverage .eslintcache dist docs/.vitepress/dist locale pnpm-lock.yaml node_modules",
6060
"build:clean": "rimraf dist",
61-
"build:code": "tsx ./scripts/bundle.ts",
61+
"build:code": "tsup-node",
6262
"build:types": "tsc --project tsconfig.build.json",
6363
"build": "run-s build:clean build:code build:types",
6464
"generate": "run-s generate:locales generate:api-docs",
@@ -101,7 +101,6 @@
101101
"@vueuse/core": "~10.4.1",
102102
"conventional-changelog-cli": "~4.1.0",
103103
"cypress": "~13.1.0",
104-
"esbuild": "~0.19.2",
105104
"eslint": "~8.49.0",
106105
"eslint-config-prettier": "~9.0.0",
107106
"eslint-define-config": "~1.23.0",
@@ -118,6 +117,7 @@
118117
"sanitize-html": "~2.11.0",
119118
"semver": "~7.5.4",
120119
"standard-version": "~9.5.0",
120+
"tsup": "~7.2.0",
121121
"tsx": "~3.12.9",
122122
"typedoc": "~0.24.8",
123123
"typescript": "~4.9.5",

0 commit comments

Comments
 (0)