Skip to content

Commit 66aecf0

Browse files
committed
chore: replace bunchee w/ rollup (let's rock)
1 parent 63114ab commit 66aecf0

File tree

4 files changed

+214
-335
lines changed

4 files changed

+214
-335
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# cors-edge
22

3-
You are writing a very simple functions that runs on edge (either on Cloudflare Workers, Fastly Edge Compute, Vercel Edge Functions, etc.) consisting of less than 100 lines of code. You want to enable CORS (Cross-Origin Resource Sharing) for your endpoint but you do not want to pull in a heavy framework with middlewares just for that. This platform-agnostic package provides a simple way to add CORS support with minimal footprint (with only `930 bytes` added to your bundle).
3+
You are writing a very simple functions that runs on edge (either on Cloudflare Workers, Fastly Edge Compute, Vercel Edge Functions, etc.) consisting of less than 100 lines of code. You want to enable CORS (Cross-Origin Resource Sharing) for your endpoint but you do not want to pull in a heavy framework with middlewares just for that. This platform-agnostic package provides a simple way to add CORS support with minimal footprint (with only `929 bytes` added to your bundle).
44

55
## Installation
66

package.json

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
"scripts": {
2323
"lint": "eslint --format=sukka .",
2424
"test": "SWC_NODE_IGNORE_DYNAMIC=1 SWC_NODE_INLINE_SOURCE_MAP=1 mocha --require @swc-node/register --parallel --full-trace ./src/**/*.test.ts",
25-
"build": "bunchee --minify --no-sourcemap",
25+
"build": "rollup -c rollup.config.ts --configPlugin swc3 --bundleConfigAsCjs",
2626
"prerelease": "pnpm run lint && pnpm run test && pnpm run build",
2727
"release": "bumpp -r --all --commit \"release: %s\" --tag \"%s\""
2828
},
@@ -35,18 +35,23 @@
3535
],
3636
"author": "SukkaW <https://skk.moe>",
3737
"license": "MIT",
38+
"dependencies": {
39+
"rollup": "^4.53.3",
40+
"rollup-plugin-swc3": "^0.12.1"
41+
},
3842
"devDependencies": {
3943
"@swc-node/register": "^1.11.1",
4044
"@swc/core": "^1.15.3",
4145
"@types/mocha": "^10.0.10",
4246
"bumpp": "^10.3.2",
43-
"bunchee": "^6.6.2",
4447
"eslint": "^9.39.1",
4548
"eslint-config-sukka": "^8.0.5",
4649
"eslint-formatter-sukka": "^8.0.5",
4750
"expect": "^30.2.0",
4851
"mocha": "^11.7.5",
49-
"typescript": "^5.9.3"
52+
"rollup-plugin-dts": "^6.3.0",
53+
"typescript": "^5.9.3",
54+
"xbits": "^0.2.0"
5055
},
5156
"packageManager": "pnpm@10.25.0"
5257
}

0 commit comments

Comments
 (0)