1
+ import Codex from "eslint-config-codex" ;
2
+ import { plugin as TsPlugin , parser as TsParser } from 'typescript-eslint' ;
3
+
4
+ export default [
5
+ ...Codex ,
6
+ {
7
+ files : [ 'src/**/*.ts' ] ,
8
+ languageOptions : {
9
+ parser : TsParser ,
10
+ parserOptions : {
11
+ project : './tsconfig.json' ,
12
+ tsconfigRootDir : './' ,
13
+ sourceType : 'module' ,
14
+ } ,
15
+ } ,
16
+ rules : {
17
+ 'n/no-missing-import' : [ 'off' ] ,
18
+ 'n/no-unsupported-features/node-builtins' : [ 'off' ] ,
19
+ 'jsdoc/require-returns-description' : [ 'off' ] ,
20
+ 'jsdoc/require-jsdoc' : [
21
+ 'error' ,
22
+ {
23
+ 'require' : {
24
+ 'FunctionDeclaration' : true ,
25
+ 'MethodDefinition' : true ,
26
+ 'ClassDeclaration' : true ,
27
+ 'ArrowFunctionExpression' : false ,
28
+ 'FunctionExpression' : false ,
29
+ }
30
+ }
31
+ ] ,
32
+ '@typescript-eslint/explicit-member-accessibility' : [ 'off' ] ,
33
+ '@typescript-eslint/naming-convention' : [
34
+ 'error' ,
35
+ {
36
+ 'selector' : 'variable' ,
37
+ 'format' : [ 'camelCase' ] ,
38
+ 'leadingUnderscore' : 'allow'
39
+ } ,
40
+ ] ,
41
+ '@typescript-eslint/no-unsafe-member-access' : [ 'off' ] ,
42
+ '@typescript-eslint/no-restricted-types' : [ 'error' ,
43
+ {
44
+ 'types' : {
45
+ 'String' : "Use 'string' instead." ,
46
+ 'Boolean' : "Use 'boolean' instead." ,
47
+ 'Number' : "Use 'number' instead." ,
48
+ 'Symbol' : "Use 'symbol' instead." ,
49
+ 'Object' : "Use 'object' instead, or define a more specific type." ,
50
+ 'Function' : "Use a specific function type instead, like '(arg: type) => returnType'."
51
+ }
52
+ }
53
+ ]
54
+ }
55
+ } ,
56
+ {
57
+ ignores : [ 'dev/**' , 'eslint.config.mjs' , 'vite.config.js' , 'postcss.config.js' ]
58
+ }
59
+ ] ;
0 commit comments