Files
order_site/apps/backend/package.json
T
yml2213 81ae04dae0 接入 ESLint 并清理未使用代码
- 前后端接入 ESLint 10 扁平配置(typescript-eslint 类型感知检查 + react-hooks/react-refresh),新增 lint / lint:check / lint:fix 脚本并纳入 check 链路
- 清理全部 no-unused-vars 与 no-useless-assignment 警告,修复 floating promises、正则转义等问题
- 删除确认无引用的死代码(markKuaishouCloudBindUrlRefreshFailed、未使用 helper 等)
2026-08-16 18:04:55 +08:00

56 lines
2.5 KiB
JSON

{
"name": "order-site-backend",
"version": "0.1.0",
"private": true,
"type": "module",
"scripts": {
"cleanup:dev-data": "tsx scripts/cleanup-dev-data.ts",
"build": "tsc -p tsconfig.build.json && rm -rf dist/db/migrations && mkdir -p dist/db && cp -R src/db/migrations dist/db/migrations",
"db:migrate": "tsx src/db/migrate.ts",
"db:migrate:create": "tsx scripts/create-migration.ts",
"db:migrate:status": "tsx scripts/migration-status.ts",
"dev": "tsx watch --clear-screen=false src/index.ts",
"format": "prettier --config ../../.prettierrc.json --ignore-path ../../.prettierignore --write \"src/**/*.{ts,js,json}\" \"scripts/**/*.{ts,js}\" eslint.config.js package.json tsconfig.json tsconfig.build.json tsconfig.eslint.json",
"format:check": "prettier --config ../../.prettierrc.json --ignore-path ../../.prettierignore --check \"src/**/*.{ts,js,json}\" \"scripts/**/*.{ts,js}\" eslint.config.js package.json tsconfig.json tsconfig.build.json tsconfig.eslint.json",
"lint": "eslint \"src/**/*.ts\" \"scripts/**/*.ts\"",
"lint:check": "npm run lint -- --quiet",
"lint:fix": "npm run lint -- --fix",
"mock:claim": "tsx scripts/mock-kuaishou-cloud-claim.ts",
"mock:open91": "tsx scripts/mock-open91-order.ts",
"test": "node --import tsx --test $(find src \\( -name '*.test.ts' -o -name '*.test.js' \\) -print)",
"test:industry": "tsx scripts/test-kuaishou-industry.ts",
"test:industry:http": "tsx scripts/test-kuaishou-industry-http.ts",
"test:industry:gen": "tsx scripts/gen-test-cases.ts",
"test:industry:curl": "tsx scripts/curl-send-callback.ts",
"typecheck": "tsc -p tsconfig.json --noEmit",
"check": "npm run format:check && npm run lint:check && npm run typecheck && npm test && npm run build",
"start": "node dist/index.js",
"start:src": "tsx src/index.ts",
"mock:feifei": "tsx scripts/mock-feifei-claim.ts"
},
"dependencies": {
"@alicloud/dysmsapi20170525": "^4.6.0",
"@alicloud/openapi-client": "^0.4.15",
"@alicloud/tea-util": "^1.4.11",
"express": "^5.1.0",
"minio": "^8.0.7",
"multer": "^2.2.0",
"node-pg-migrate": "^8.0.4",
"pg": "^8.16.3",
"sharp": "^0.35.3"
},
"devDependencies": {
"@eslint/js": "10.0.1",
"@types/express": "^5.0.6",
"@types/multer": "^2.2.0",
"@types/node": "^25.6.0",
"@types/pg": "^8.20.0",
"eslint": "10.8.1",
"globals": "17.11.0",
"prettier": "3.8.3",
"tsx": "^4.22.3",
"typescript": "^6.0.2",
"typescript-eslint": "8.67.0"
}
}