mirror of
https://github.com/Egonex-AI/Understand-Anything.git
synced 2026-06-22 10:58:03 +08:00
chore: add ESLint tooling with TypeScript support
The repository has a pnpm lint script running 'eslint .' but ESLint and typescript-eslint were not listed in devDependencies. Added: - eslint (^9.0.0) - @eslint/js (^9.0.0) - typescript-eslint (^8.0.0) Added eslint.config.mjs with flat config (ESLint 9+) using typescript-eslint strict rules. Ignores node_modules, dist, build, and framework-specific output directories.
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
import eslint from '@eslint/js';
|
||||
import tseslint from 'typescript-eslint';
|
||||
|
||||
export default tseslint.config(
|
||||
eslint.configs.recommended,
|
||||
...tseslint.configs.strict,
|
||||
{
|
||||
files: ['**/*.ts', '**/*.tsx', '**/*.mts', '**/*.cts'],
|
||||
languageOptions: {
|
||||
parserOptions: {
|
||||
projectService: {
|
||||
allowDefaultProject: ['*.config.*'],
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
ignores: [
|
||||
'**/node_modules/**',
|
||||
'**/dist/**',
|
||||
'**/build/**',
|
||||
'**/.understand-anything/**',
|
||||
'**/.claude-plugin/**',
|
||||
'**/.cursor-plugin/**',
|
||||
'**/.copilot-plugin/**',
|
||||
'**/coverage/**',
|
||||
],
|
||||
},
|
||||
);
|
||||
@@ -12,7 +12,10 @@
|
||||
"lint": "eslint ."
|
||||
},
|
||||
"devDependencies": {
|
||||
"@eslint/js": "^9.0.0",
|
||||
"eslint": "^9.0.0",
|
||||
"typescript": "^5.7.0",
|
||||
"typescript-eslint": "^8.0.0",
|
||||
"vitest": "^3.1.0"
|
||||
},
|
||||
"pnpm": {
|
||||
|
||||
Reference in New Issue
Block a user