Files
CipherStreamWeb/eslint.config.js
2026-08-15 17:28:19 -04:00

46 lines
1.2 KiB
JavaScript

import js from "@eslint/js";
import pluginRouter from "@tanstack/eslint-plugin-router";
import eslintReact from "@eslint-react/eslint-plugin";
import reactHooks from "eslint-plugin-react-hooks";
import reactRefresh from "eslint-plugin-react-refresh";
import globals from "globals";
import tseslint from "typescript-eslint";
import { defineConfig, globalIgnores } from "eslint/config";
export default defineConfig(
globalIgnores(["dist", "coverage", ".tanstack", ".scannerwork"]),
{
files: ['**/*.{ts,tsx}'],
extends: [
js.configs.recommended,
eslintReact.configs.recommended,
tseslint.configs.recommendedTypeChecked,
reactHooks.configs.flat["recommended-latest"],
reactRefresh.configs.vite,
pluginRouter.configs["flat/recommended"]
],
languageOptions: {
ecmaVersion: 2022,
globals: globals.browser,
parserOptions: {
project: ["./tsconfig.node.json", "./tsconfig.app.json"],
tsconfigRootDir: import.meta.dirname
}
},
rules: {
...reactHooks.configs.recommended.rules,
"react-refresh/only-export-components": [
"warn",
{ allowConstantExport: true }
],
"react/react-in-jsx-scope": "off"
},
settings: {
react: {
version: "detect",
}
}
}
);