diff --git a/bunfig.toml b/bunfig.toml index 7b7aab7..f48c77a 100644 --- a/bunfig.toml +++ b/bunfig.toml @@ -20,4 +20,17 @@ dir = ".bun" disable = false [debug] -port = 9229 \ No newline at end of file +port = 9229 + +[env] +# Environment-specific configurations +development.LOG_LEVEL = "debug" +production.LOG_LEVEL = "warn" + +[hot] +restart = true +reload = true + +[performance] +gc = true +optimize = true \ No newline at end of file diff --git a/package.json b/package.json index c496195..4b1ffd1 100644 --- a/package.json +++ b/package.json @@ -6,14 +6,18 @@ "type": "module", "scripts": { "start": "bun run dist/index.js", - "dev": "bun run --watch src/index.ts", - "build": "bun build ./src/index.ts --outdir ./dist --target node", + "dev": "bun --hot --watch src/index.ts", + "build": "bun build ./src/index.ts --outdir ./dist --target node --minify", "test": "bun test", "test:watch": "bun test --watch", "test:coverage": "bun test --coverage", "lint": "eslint . --ext .ts", "format": "prettier --write \"src/**/*.ts\"", - "prepare": "husky install" + "prepare": "husky install", + "profile": "bun --inspect src/index.ts", + "clean": "rm -rf dist .bun", + "typecheck": "bun x tsc --noEmit", + "preinstall": "bun install --frozen-lockfile" }, "dependencies": { "@elysiajs/cors": "^1.2.0", diff --git a/tsconfig.json b/tsconfig.json index 3f7c712..1399f22 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,44 +1,36 @@ { "compilerOptions": { - "target": "ES2022", - "module": "NodeNext", - "moduleResolution": "NodeNext", - "outDir": "dist", - "rootDir": ".", + "target": "esnext", + "module": "esnext", + "lib": [ + "esnext", + "dom" + ], "strict": true, "esModuleInterop": true, "skipLibCheck": true, "forceConsistentCasingInFileNames": true, + "moduleResolution": "node", "resolveJsonModule": true, - "declaration": true, - "sourceMap": true, - "allowJs": true, - "experimentalDecorators": true, - "emitDecoratorMetadata": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react-jsx", "types": [ "bun-types" ], - "typeRoots": [ - "./node_modules/@types" - ], - "lib": [ - "ES2022" - ], "baseUrl": ".", "paths": { - "*": [ - "node_modules/*" + "@/*": [ + "./src/*" ] } }, "include": [ "src/**/*", - "__tests__/**/*", - "jest.config.ts" + "__tests__/**/*" ], "exclude": [ "node_modules", - "dist", - "coverage" + "dist" ] } \ No newline at end of file