Skip to content

Commit

Permalink
Use eslint 9 config
Browse files Browse the repository at this point in the history
  • Loading branch information
timowestnosto committed Nov 4, 2024
1 parent 65e82e6 commit 726d2ca
Show file tree
Hide file tree
Showing 3 changed files with 104 additions and 328 deletions.
25 changes: 10 additions & 15 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,22 +1,17 @@
import tsParser from "@typescript-eslint/parser"
import js from "@eslint/js"
import { FlatCompat } from "@eslint/eslintrc"

const compat = new FlatCompat({
recommendedConfig: js.configs.recommended,
allConfig: js.configs.all
})
import eslint from "@eslint/js"
import tseslint from "typescript-eslint"
import pluginPromise from 'eslint-plugin-promise'
import reactPlugin from 'eslint-plugin-react'

export default [
...compat.extends(
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:promise/recommended",
"plugin:react/recommended"
),
eslint.configs.recommended,
pluginPromise.configs['flat/recommended'],
...tseslint.configs.recommended,
reactPlugin.configs.flat.recommended,
reactPlugin.configs.flat['jsx-runtime'],
{
languageOptions: {
parser: tsParser,
...reactPlugin.configs.flat.recommended.languageOptions,
ecmaVersion: "latest",
sourceType: "module"
},
Expand Down
Loading

0 comments on commit 726d2ca

Please sign in to comment.