Update Biome check command and improve server build setup

This commit is contained in:
Aman Varshney
2025-03-23 15:11:55 +05:30
parent a2f71761ba
commit c605c7c075
3 changed files with 20 additions and 17 deletions

View File

@@ -73,7 +73,7 @@ async function setupHusky(projectDir: string) {
packageJson["lint-staged"] = { packageJson["lint-staged"] = {
"*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}": [ "*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}": [
"biome check --no-errors-on-unmatched --files-ignore-unknown=true", "biome check --write .",
], ],
}; };

View File

@@ -4,7 +4,8 @@
"type": "module", "type": "module",
"scripts": { "scripts": {
"dev": "tsx watch src/index.ts", "dev": "tsx watch src/index.ts",
"build": "tsc", "start": "node dist/src/index.js",
"build": "tsc && tsc-alias",
"dev:bun": "bun run --hot src/index.ts", "dev:bun": "bun run --hot src/index.ts",
"check-types": "tsc --noEmit", "check-types": "tsc --noEmit",
"compile": "bun build --compile --minify --sourcemap --bytecode ./src/index.ts --outfile server" "compile": "bun build --compile --minify --sourcemap --bytecode ./src/index.ts --outfile server"
@@ -18,6 +19,7 @@
"zod": "^3.24.2" "zod": "^3.24.2"
}, },
"devDependencies": { "devDependencies": {
"tsc-alias": "^1.8.11",
"tsx": "^4.19.2", "tsx": "^4.19.2",
"@types/node": "^22.13.11", "@types/node": "^22.13.11",
"typescript": "^5.8.2" "typescript": "^5.8.2"

View File

@@ -1,17 +1,18 @@
{ {
"compilerOptions": { "compilerOptions": {
"target": "ESNext", "target": "ESNext",
"module": "ESNext", "module": "ESNext",
"moduleResolution": "bundler", "moduleResolution": "bundler",
"allowImportingTsExtensions": true, "verbatimModuleSyntax": true,
"esModuleInterop": true, "strict": true,
"verbatimModuleSyntax": true, "skipLibCheck": true,
"noEmit": true, "baseUrl": "./",
"strict": true, "outDir": "./dist",
"skipLibCheck": true, "types": ["node"],
"outDir": "./dist", "jsx": "react-jsx",
"types": ["node"], "jsxImportSource": "hono/jsx"
"jsx": "react-jsx", },
"jsxImportSource": "hono/jsx" "tsc-alias": {
} "resolveFullPaths": true
}
} }