-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy patheslint.config.js
More file actions
46 lines (41 loc) · 1.02 KB
/
Copy patheslint.config.js
File metadata and controls
46 lines (41 loc) · 1.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/**
* ESLint flat config for Neuron OS.
* Uses @typescript-eslint parser + plugin for TypeScript strictness.
*
* @see https://eslint.org/docs/latest/use/configure/configuration-files
*/
// @ts-check
import tseslint from "typescript-eslint"
export default tseslint.config(
// Global ignores
{
ignores: [
"dist/",
"node_modules/",
"dashboard/dist/",
"*.config.*",
"bun.lock",
],
},
// Apply to all TS files
...tseslint.configs.recommended,
// Custom rules
{
rules: {
"@typescript-eslint/no-unused-vars": ["warn", { argsIgnorePattern: "^_" }],
"@typescript-eslint/no-explicit-any": "warn",
"@typescript-eslint/no-non-null-assertion": "warn",
"no-console": "off",
"prefer-const": "error",
"no-var": "error",
},
},
// Test files — allow more flexibility
{
files: ["**/test-*.ts", "**/*.test.ts"],
rules: {
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-non-null-assertion": "off",
},
},
)