@buildinams/lint
Version:
BiA's base lint config(s).
24 lines (22 loc) • 572 B
JavaScript
const tseslint = require("typescript-eslint");
module.exports = [
...tseslint.configs.recommended,
{
rules: {
"no-restricted-syntax": [
"error",
{
selector: "TSEnumDeclaration",
message: "Use `const Foo as const` with `typeof Foo` over Enum",
},
],
"@typescript-eslint/consistent-type-definitions": ["error", "type"],
},
},
{
// TS compiler handles undefined variables — no-undef false-positives
// on global types (JSX.Element, NodeJS.Timeout, etc.)
files: ["**/*.{ts,tsx,mts,cts}"],
rules: { "no-undef": "off" },
},
];