Back to results
gajus/eslint-plugin-zod(opens in a new tab)
Language: TypeScript
Zod linting rules for ESLint.
- stars
- 26
- watchers
- 2
- forks
- 3
- open issues
- 5
- Last updated
- 01/15/2026
Language: TypeScript
Zod linting rules for ESLint.
Warning
The source code of eslint-plugin-zod now resides here:
https://github.com/marcalexiei/eslint-plugin-zod
For additional context, see Takeover of eslint-plugin-zod.
Zod linting rules for ESLint.
eslint-plugin-zod plugin.npm install eslint --save-dev npm install eslint-plugin-zod --save-dev
plugins section and specify eslint-plugin-zod as a plugin.{
"plugins": [
"zod"
],
"rules": {
"zod/prefer-enum": 2,
"zod/require-strict": 2
}
}
The --fix option on the command line automatically fixes problems reported by this rule.
Prefers z.enum over a union of literals.
The --fix option on the command line automatically fixes problems reported by this rule.
Requires that objects are initialized with .strict().
| configuration | format | default | description |
|---|---|---|---|
allowPassthrough |
boolean | true |
Ignores objects explicitly set to allowPassthrough(). |