- 前后端接入 ESLint 10 扁平配置(typescript-eslint 类型感知检查 + react-hooks/react-refresh),新增 lint / lint:check / lint:fix 脚本并纳入 check 链路 - 清理全部 no-unused-vars 与 no-useless-assignment 警告,修复 floating promises、正则转义等问题 - 删除确认无引用的死代码(markKuaishouCloudBindUrlRefreshFailed、未使用 helper 等)
47 lines
1.8 KiB
JSON
47 lines
1.8 KiB
JSON
{
|
|
"name": "order-site-frontend",
|
|
"private": true,
|
|
"version": "0.1.0",
|
|
"type": "module",
|
|
"scripts": {
|
|
"dev": "vite",
|
|
"build": "tsc -b && vite build",
|
|
"format": "prettier --config ../../.prettierrc.json --ignore-path ../../.prettierignore --write \"src/**/*.{ts,tsx,js,jsx,json,css}\" \"tests/**/*.{ts,tsx,js,jsx}\" eslint.config.js package.json tsconfig.json tsconfig.eslint.json vite.config.ts index.html",
|
|
"format:check": "prettier --config ../../.prettierrc.json --ignore-path ../../.prettierignore --check \"src/**/*.{ts,tsx,js,jsx,json,css}\" \"tests/**/*.{ts,tsx,js,jsx}\" eslint.config.js package.json tsconfig.json tsconfig.eslint.json vite.config.ts index.html",
|
|
"lint": "eslint \"src/**/*.{ts,tsx}\" \"tests/**/*.{ts,tsx}\" vite.config.ts",
|
|
"lint:check": "npm run lint -- --quiet",
|
|
"lint:fix": "npm run lint -- --fix",
|
|
"test": "node --experimental-strip-types --test tests/*.test.ts",
|
|
"typecheck": "tsc -b --noEmit",
|
|
"check": "npm run format:check && npm run lint:check && npm run typecheck && npm test && npm run build",
|
|
"preview": "vite preview"
|
|
},
|
|
"dependencies": {
|
|
"@ant-design/icons": "^6.1.0",
|
|
"@tanstack/react-query": "^5.90.12",
|
|
"antd": "^6.1.1",
|
|
"axios": "^1.13.2",
|
|
"dayjs": "^1.11.21",
|
|
"qrcode": "^1.5.4",
|
|
"react": "^19.2.3",
|
|
"react-dom": "^19.2.3",
|
|
"react-router": "^7.10.1"
|
|
},
|
|
"devDependencies": {
|
|
"@eslint/js": "10.0.1",
|
|
"@types/node": "^25.6.0",
|
|
"@types/qrcode": "^1.5.6",
|
|
"@types/react": "^19.2.7",
|
|
"@types/react-dom": "^19.2.3",
|
|
"@vitejs/plugin-react": "^6.0.1",
|
|
"eslint": "10.8.1",
|
|
"eslint-plugin-react-hooks": "7.1.1",
|
|
"eslint-plugin-react-refresh": "0.5.4",
|
|
"globals": "17.11.0",
|
|
"prettier": "3.8.3",
|
|
"typescript": "~6.0.2",
|
|
"typescript-eslint": "8.67.0",
|
|
"vite": "^8.0.7"
|
|
}
|
|
}
|