feat(ui): add comprehensive quality gates and fix linting issues

- Added ESLint, Prettier, TypeScript strict mode to ui/ directory
- Fixed 40+ lint/format issues across ui codebase
- Created extraction files for react-refresh compliance:
  - button-variants.ts for Button component styles
  - use-sidebar.ts, use-websocket-context.ts custom hooks
  - ws-context.ts WebSocket context provider
- Fixed React hooks issues (setState ordering, dependency arrays)
- Added ui:validate script to enforce quality checks
- Updated husky pre-commit to validate UI files on change
This commit is contained in:
kaitranntt committed 2025-12-07 14:51:29 -05:00
1 parent 59758024c9
commit 707af2f01a
59 files changed
+929 -2835

No files matched your search

+7
View File
@@ -6,7 +6,12 @@
"scripts": {
"dev": "vite",
"build": "tsc -b && vite build",
"typecheck": "tsc -b --noEmit",
"lint": "eslint .",
"lint:fix": "eslint . --fix",
"format": "prettier --write src/",
"format:check": "prettier --check src/",
"validate": "bun run typecheck && bun run lint:fix && bun run format:check",
"preview": "vite preview"
},
"dependencies": {
@@ -40,9 +45,11 @@
"@types/react-dom": "^19.2.3",
"@vitejs/plugin-react": "^5.1.1",
"eslint": "^9.39.1",
"eslint-config-prettier": "^10.1.8",
"eslint-plugin-react-hooks": "^7.0.1",
"eslint-plugin-react-refresh": "^0.4.24",
"globals": "^16.5.0",
"prettier": "^3.6.2",
"tailwindcss": "^4.1.17",
"typescript": "~5.9.3",
"typescript-eslint": "^8.46.4",