Skip to content

Commit

Permalink
🧹 chore: bump version
Browse files Browse the repository at this point in the history
  • Loading branch information
SaltyAom committed Jul 16, 2024
1 parent 1633f41 commit bc0f7be
Show file tree
Hide file tree
Showing 10 changed files with 122 additions and 897 deletions.
6 changes: 6 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
.git
.github
.gitignore
.prettierrc
.prettierrcignore
.cjs.swcrc
.es.swcrc
bun.lockb
Expand All @@ -20,3 +22,7 @@ CHANGELOG.md
.eslintrc.js
tsconfig.cjs.json
tsconfig.esm.json
tsconfig.dts.json

src
build.ts
10 changes: 5 additions & 5 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"semi": false,
"singleQuote": true,
"tabWidth": 4,
"useTabs": false,
"trailingComma": "none"
"useTabs": true,
"tabWidth": 4,
"semi": false,
"singleQuote": true,
"trailingComma": "none"
}
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,14 @@

# 1.1.0 - 16 Jul 2024
Change:
- Add support for Elysia 1.1


# 1.1.0-rc.0 - 12 Jul 2024
Change:
- Add support for Elysia 1.1


# 1.0.3 - 24 Apr 2024
Improvement:
- [#26](https://github.com/elysiajs/elysia-static/pull/26) support system paths (windows)
Expand Down
37 changes: 37 additions & 0 deletions build.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
import { $ } from 'bun'
import { build, type Options } from 'tsup'

await $`rm -rf dist`

const tsupConfig: Options = {
entry: ['src/**/*.ts'],
splitting: false,
sourcemap: false,
clean: true,
bundle: true
} satisfies Options

await Promise.all([
// ? tsup esm
build({
outDir: 'dist',
format: 'esm',
target: 'node20',
cjsInterop: false,
...tsupConfig
}),
// ? tsup cjs
build({
outDir: 'dist/cjs',
format: 'cjs',
target: 'node20',
// dts: true,
...tsupConfig
})
])

await $`tsc --project tsconfig.dts.json`

await Promise.all([$`cp dist/*.d.ts dist/cjs`])

process.exit()
Binary file modified bun.lockb
Binary file not shown.
103 changes: 52 additions & 51 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,53 +1,54 @@
{
"name": "@elysiajs/static",
"version": "1.0.3",
"author": {
"name": "saltyAom",
"url": "https://github.com/SaltyAom",
"email": "[email protected]"
},
"repository": {
"type": "git",
"url": "https://github.com/elysiajs/elysia-static"
},
"main": "./dist/index.js",
"devDependencies": {
"@types/bun": "^1.0.4",
"@types/node": "^20.1.4",
"@typescript-eslint/eslint-plugin": "^6.7.4",
"elysia": "1.0.2",
"eslint": "^8.40.0",
"rimraf": "4.4.1",
"typescript": "^5.2.2"
},
"peerDependencies": {
"elysia": ">= 1.0.2"
},
"exports": {
"bun": "./dist/index.js",
"node": "./dist/cjs/index.js",
"require": "./dist/cjs/index.js",
"import": "./dist/index.js",
"default": "./dist/index.js"
},
"bugs": "https://github.com/elysiajs/elysia-static/issues",
"description": "Plugin for Elysia for serving static folder",
"homepage": "https://github.com/elysiajs/elysia-static",
"keywords": [
"elysia",
"static",
"public"
],
"license": "MIT",
"scripts": {
"dev": "bun run --hot example/index.ts",
"test": "bun test && npm run test:node",
"test:node": "npm install --prefix ./test/node/cjs/ && npm install --prefix ./test/node/esm/ && node ./test/node/cjs/index.js && node ./test/node/esm/index.js",
"build": "rimraf dist && tsc --project tsconfig.esm.json && tsc --project tsconfig.cjs.json",
"release": "npm run build && npm run test && npm publish --access public"
},
"types": "./src/index.ts",
"dependencies": {
"node-cache": "^5.1.2"
}
"name": "@elysiajs/static",
"version": "1.1.0",
"license": "MIT",
"scripts": {
"dev": "bun run --hot example/index.ts",
"test": "bun test && npm run test:node",
"test:node": "npm install --prefix ./test/node/cjs/ && npm install --prefix ./test/node/esm/ && node ./test/node/cjs/index.js && node ./test/node/esm/index.js",
"build": "bun build.ts",
"release": "npm run build && npm run test && npm publish --access public"
},
"main": "./dist/cjs/index.js",
"types": "./dist/index.d.ts",
"module": "./dist/index.mjs",
"exports": {
"./package.json": "./package.json",
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/cjs/index.js"
}
},
"dependencies": {
"node-cache": "^5.1.2"
},
"devDependencies": {
"@types/bun": "1.1.6",
"@typescript-eslint/eslint-plugin": "^6.7.4",
"elysia": ">= 1.1.0-rc.2",
"eslint": "9.6.0",
"tsup": "^8.1.0",
"typescript": "^5.5.3"
},
"peerDependencies": {
"elysia": ">= 1.1.0"
},
"keywords": [
"elysia",
"static",
"public"
],
"author": {
"name": "saltyAom",
"url": "https://github.com/SaltyAom",
"email": "[email protected]"
},
"repository": {
"type": "git",
"url": "https://github.com/elysiajs/elysia-static"
},
"bugs": "https://github.com/elysiajs/elysia-static/issues",
"description": "Plugin for Elysia for serving static folder",
"homepage": "https://github.com/elysiajs/elysia-static"
}
Loading

0 comments on commit bc0f7be

Please sign in to comment.