@plumile/eslint-config-typescript
v0.1.38
Published
Shared ESLint flat config tuned for TypeScript-forward React projects
Downloads
76
Readme
@plumile/eslint-config-typescript
Shared ESLint configuration optimized for TypeScript-heavy React projects inside the Plumile ecosystem.
Installation
npm install --save-dev eslint @plumile/eslint-config-typescriptIf you lint React or JSX files, ensure @typescript-eslint/eslint-plugin, eslint-plugin-react, and related peer dependencies are available. They are bundled transitively in the router workspace, but declare them explicitly if you use the config standalone.
Usage
Add the preset to your flat ESLint config (recommended) or .eslintrc file.
Flat Config (eslint.config.js)
import plumileTs from '@plumile/eslint-config-typescript';
export default [
...plumileTs,
{
files: ['packages/**/*.ts', 'packages/**/*.tsx'],
rules: {
// Project-specific overrides go here
'@typescript-eslint/no-explicit-any': 'off',
},
},
];Legacy .eslintrc
{
"extends": ["@plumile/eslint-config-typescript"],
"rules": {
"@typescript-eslint/no-explicit-any": "off"
}
}What You Get
- Strict TypeScript analysis (no implicit
any, consistent casing, unused symbol checks). - React best practices (hooks rules, JSX runtime defaults).
- Import ordering and module boundary enforcement.
- Prettier alignment where applicable (single quotes, spacing).
The preset ships multiple config fragments; eslint.config.js in the repo shows how we layer additional overrides for tests and generated files. Copy those patterns when adapting to other workspaces.
Extending Rules
Because the package exports an array of config objects, you can spread it and append overrides. Common adjustments:
- Disable costly rules in generated code directories via
ignores. - Relax naming conventions for GraphQL fragments or relay artifacts.
- Add custom plugins (e.g., router DX rule
@plumile-router/dx/no-direct-window-location-search).
Related Tooling
- Prettier runs separately via
npm run prettier:apply. - Husky + lint-staged invoke Prettier before commits; ESLint runs through
npm run eslint. - See
AGENTS.mdfor contributor workflow expectations.
