.agents/skills/eslint/SKILL.md
ESLint - pluggable JavaScript/TypeScript linter USE WHEN: user mentions "ESLint", "JavaScript linting", ".eslintrc", asks about "eslint config", "linting rules", "eslint plugins", "flat config" DO NOT USE FOR: Biome - use `eslint-biome` skill, TypeScript-specific - use `typescript-eslint` skill, code quality principles - use `quality-common`
npx skillsauth add d-subrahmanyam/deno-fresh-microservices eslintInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
eslint-biome skill for modern setuptypescript-eslint skillquality-common for SOLID/Clean Codesonarqube skillDeep Knowledge: Use
mcp__documentation__fetch_docswith technology:eslintfor comprehensive documentation.
npm install -D eslint @eslint/js
npx eslint --init
import js from '@eslint/js';
import tseslint from 'typescript-eslint';
export default [
js.configs.recommended,
...tseslint.configs.recommended,
{
files: ['**/*.ts', '**/*.tsx'],
rules: {
'@typescript-eslint/no-unused-vars': 'error',
'@typescript-eslint/explicit-function-return-type': 'warn',
},
},
{
ignores: ['dist/', 'node_modules/', '*.config.js'],
},
];
import eslintConfigPrettier from 'eslint-config-prettier';
export default [
js.configs.recommended,
...tseslint.configs.recommended,
eslintConfigPrettier, // Must be last
];
{
"root": true,
"env": { "browser": true, "es2021": true, "node": true },
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended"
],
"parser": "@typescript-eslint/parser",
"plugins": ["@typescript-eslint"],
"rules": {
"no-console": "warn",
"@typescript-eslint/no-explicit-any": "error"
}
}
# Lint files
npx eslint src/
# Fix auto-fixable issues
npx eslint src/ --fix
# Check specific files
npx eslint "src/**/*.{ts,tsx}"
| Anti-Pattern | Why It's Bad | Correct Approach |
|--------------|--------------|------------------|
| Using legacy .eslintrc in new projects | Deprecated in ESLint 9 | Use flat config (eslint.config.mjs) |
| No TypeScript type checking | Misses type-aware issues | Use recommendedTypeChecked preset |
| Disabling rules with comments everywhere | Code smell, defeats purpose | Fix the issue or adjust rule config |
| Not caching in CI | Slow linting | Use --cache flag |
| Conflicting Prettier rules | Formatting wars | Use eslint-config-prettier |
| Ignoring warnings | Accumulate tech debt | Treat warnings as errors in CI |
| Issue | Likely Cause | Solution |
|-------|--------------|----------|
| "Failed to load config" error | Wrong config format | Check eslint.config.mjs syntax |
| Type-aware rules not working | Missing parserOptions | Add projectService: true to config |
| Linting very slow | No caching, type checking all files | Enable cache, limit type checking to TS files |
| Rules from plugin not found | Plugin not in flat config format | Check plugin compatibility with ESLint 9 |
| Prettier conflicts | Both formatting same code | Add eslint-config-prettier last |
| File not being linted | In ignores array | Check ignores in config |
development
Guidelines for building high-performance APIs with Fastify and TypeScript, covering validation, Prisma integration, and testing best practices
development
FastAPI modern Python web framework. Covers routing, Pydantic models, dependency injection, and async support. Use when building Python APIs. USE WHEN: user mentions "fastapi", "pydantic", "async python api", "python rest api", asks about "dependency injection python", "python openapi", "python swagger", "async endpoints", "python api validation", "fastapi middleware" DO NOT USE FOR: Django apps - use `django` instead, Flask apps - use `flask` instead, synchronous Python APIs without type hints, GraphQL-only APIs
tools
FastAPI integration testing specialist. Covers synchronous TestClient, async httpx AsyncClient, dependency injection overrides, auth testing (JWT, OAuth2, API keys), WebSocket testing, file uploads, background tasks, middleware testing, and HTTP mocking with respx, responses, and pytest-httpserver. USE WHEN: user mentions "FastAPI test", "TestClient", "httpx async test", "dependency override test", "respx mock", asks about testing FastAPI endpoints, authentication in tests, or HTTP client mocking. DO NOT USE FOR: Django - use `pytest-django`; pytest internals - use `pytest`; Container infrastructure - use `testcontainers-python`
development
Expert in FastAPI Python development with best practices for APIs and async operations