mirror of
https://github.com/linsa-io/linsa.git
synced 2026-01-12 12:20:23 +01:00
chore: project config and docs (#152)
* refactor(eslint): improve config readability and structure * chore(tsconfig): group options and add explanatory comments * docs(readme): restructure for clearer setup and contribution guide
This commit is contained in:
@@ -3,22 +3,22 @@ import js from "@eslint/js"
|
||||
|
||||
const compat = new FlatCompat()
|
||||
|
||||
const typescriptConfig = compat.extends(
|
||||
"eslint:recommended",
|
||||
"plugin:@typescript-eslint/recommended-type-checked",
|
||||
"plugin:@typescript-eslint/stylistic-type-checked",
|
||||
"prettier"
|
||||
)
|
||||
|
||||
const javascriptConfig = js.configs.recommended
|
||||
|
||||
export default [
|
||||
{
|
||||
...compat
|
||||
.extends(
|
||||
"eslint:recommended",
|
||||
"plugin:@typescript-eslint/recommended-type-checked",
|
||||
"plugin:@typescript-eslint/stylistic-type-checked",
|
||||
"prettier"
|
||||
)
|
||||
.map(c => ({
|
||||
...c,
|
||||
files: ["**/*.{ts,tsx,mts}"]
|
||||
}))
|
||||
files: ["**/*.{ts,tsx,mts}"],
|
||||
...typescriptConfig
|
||||
},
|
||||
{
|
||||
files: ["**/*.{js,jsx,cjs,mjs}"],
|
||||
...js.configs.recommended
|
||||
...javascriptConfig
|
||||
}
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user