37 lines
838 B
JavaScript
37 lines
838 B
JavaScript
/** @type {import("eslint").Linter.Config} */
|
|
const config = {
|
|
overrides: [
|
|
{
|
|
extends: [
|
|
"plugin:@typescript-eslint/recommended-requiring-type-checking",
|
|
],
|
|
files: ["*.ts", "*.tsx"],
|
|
parserOptions: {
|
|
project: "tsconfig.json",
|
|
},
|
|
},
|
|
],
|
|
parser: "@typescript-eslint/parser",
|
|
parserOptions: {
|
|
project: "./tsconfig.json",
|
|
},
|
|
plugins: ["@typescript-eslint"],
|
|
extends: ["next/core-web-vitals", "plugin:@typescript-eslint/recommended"],
|
|
rules: {
|
|
"@typescript-eslint/consistent-type-imports": [
|
|
"warn",
|
|
{
|
|
prefer: "type-imports",
|
|
fixStyle: "inline-type-imports",
|
|
},
|
|
],
|
|
"@typescript-eslint/ban-ts-comment": [
|
|
"error",
|
|
{
|
|
"ts-ignore": "allow-with-description",
|
|
},
|
|
],
|
|
},
|
|
};
|
|
|
|
module.exports = config;
|