@pandell/eslint-config
v9.6.0
Published
Pandell ESLint shared config
Downloads
263
Maintainers
Readme
@pandell/eslint-config
Shared ESLint config for Pandell engineering teams.
Usage
Add the following to your package.json
:
{
"resolutions": {
"@typescript-eslint/utils": "^8.13.0" // see note 1
},
"devDependencies": {
"@pandell/eslint-config": "^9.6.0",
"eslint": "^9.14.0",
// ...
},
// ...
}
Note 1
eslint-plugin-testing-library
depends on a very old version oftypescript-eslint
library for no good reason. We recommend resolving it to the latest version, to be consistent with@pandell/eslint-config
. We should be able to remove the resolution once testing library plugin upgrades to the latest major version oftypescript-eslint
.
Next, create eslint.config.mjs
in the root of your project. Explore available properties
in the settings object passed to createPandellEsLintConfig
function (see PandellEsLintConfigSettings
in node_modules/@pandell/eslint-config/dist/pandellEsLintConfig.d.ts
). Example contents:
// @ts-check
import { createPandellEsLintConfig } from "@pandell/eslint-config";
export default createPandellEsLintConfig({
// type-checked typescript is enabled by default; to disable type-checking
// rules, uncomment the following line:
// typeScript: { typeChecked: false },
react: { enabled: true },
vite: { enabled: true },
testing: { enabledJsDom: true, enabledTestingLibrary: true },
});
For more details and options for configuration, see the ESLint documentation.