$ gnpm install types-eslintrc
Type checking for ESLint configs.
If I should maintain this repo, please ⭐️
DM me on Twitter if you have questions or suggestions.
This package uses zod to type check ESLint configs.
yarn add types-eslintrc
npm install types-eslintrc
pnpm add types-eslintrc
import {
ESLintConfig,
isESLintConfig,
parseESLintConfig
} from "types-eslintrc";
const myConfig = {
// ...
};
if(isESLintConfig(myConfig)) {
// myConfig is now typed as ESLintConfig
}
const myConfig = parseESLintConfig(myConfig);
// If myConfig is valid, it will return as ESLintConfig. Otherwise, it will return undefined.
MIT - MIT License
Copyright 2013 - present © cnpmjs.org | Home |