Welcome to the ultimate ESLint setup — no fluff, just what you need to write clean, bug-free code. Say goodbye to unnecessary stress and hello to a smooth dev experience! 🎉
- As simple as flat configs can be — without re-inventing the classic nested config,
- Keeps your codebase clean while reducing friction 🧘,
- Focuses on catching bugs, not dictating your coding style 🐛,
- Minimal but configurable — use only what you need 🔧,
- Bundled support for TypeScript, React.js, Playwright, Storybook, Vitest, and more,
- DOES NOT enforce import sorting or stylistic formatting (that's a job for Prettier 😉),
- Works with eslint v9+
Note
Starting from @zemd/eslint-flat-config
@v3.2.0, the package was split into multiple packages. Pick what suits your project best! 🛠️
Package | Registry | Description |
---|---|---|
@zemd/eslint-js |
JavaScript-only rules. | |
@zemd/eslint-ts |
TypeScript rules (includes JS rules from @zemd/eslint-js). | |
@zemd/eslint-react |
React rules (includes TS rules from @zemd/eslint-ts and JS rules from @zemd/eslint-js ). |
|
@zemd/eslint-rock-stack |
Rules for Fullstack projects that include React.js, GraphQL, Playwright, Tailwind(optional), Turbo, Vitest, and Storybook. | |
@zemd/eslint-next |
Rules for Next.js projects (inherits from @zemd/eslint-rock-stack ). |
npm install --save-dev eslint @zemd/eslint-rock-stack
// eslint.config.js
import { typescript, storybook } from "@zemd/eslint-rock-stack";
export default [
...typescript(),
...storybook({
filesMain: ["./packages/storybook/.storybook/main.js"],
filesStories: ["./packages/storybook/**/*.{stories,story}.{js,jsx,ts,tsx}"],
}),
];
Want to remove specific rules? Just filter them out! 🔥
// eslint.config.js
import rock from "@zemd/eslint-rock-stack";
export default rock().filter((feature) => !feature.name.startsWith("zemd/graphql"));
Or cherry-pick only what you need:
// eslint.config.js
import { javascript, typescript, vitest } from "@zemd/eslint-rock-stack";
export default [...javascript(), ...typescript(), ...vitest()];
npm pkg set scripts.lint="eslint ."
npm pkg set scripts.lint:fix="eslint . --fix"
or manually:
{
"scripts": {
"lint": "eslint .",
"lint:fix": "eslint . --fix"
}
}
Use @eslint/config-inspector
to debug your ESLint setup.
npx @eslint/config-inspector@latest
# or
bunx @eslint/config-inspector@latest
This monorepo is all about making your life easier — less tool stress, more confidence. Here’s the philosophy behind it:
- 💠 No tool should block you from using language features,
- 💠 Minimal warnings, just meaningful errors that help (not annoy) you.
- 💠 No formatting rules — Prettier handles that so you don’t have to debate semicolons,
- 💠 Simple configuration — just native JS arrays, no unnecessary abstractions,
- 💠 Batteries included 🔋: Enable only what you need (TypeScript, React, Next.js, Tailwind, Vitest, Playwright, Storybook, etc.).
- 💠 Rules guide you to write better code, not force a rigid style.
- Sheriff -- Great, but includes some stylistic restrictions,
- Antfu config -- Another solid choice,
- XO -- Flat version of
xo
, but still in beta.
All packages in this monorepo are licensed under Apache-2.0 license 😇.