Repository navigation
Expand file tree
/
Copy pathbiome.jsonc
More file actions
140 lines (140 loc) · 4.79 KB
/
Copy pathbiome.jsonc
File metadata and controls
140 lines (140 loc) · 4.79 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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
{
"$schema": "./node_modules/@biomejs/biome/configuration_schema.json",
"vcs": { "enabled": true, "clientKind": "git", "useIgnoreFile": true },
"files": {
"ignoreUnknown": true,
"includes": [
"**",
"!doc/.vitepress/dist",
"!doc/.vitepress/cache",
"!package-lock.json",
"!**/*.pegjs"
]
},
"formatter": {
"enabled": true,
// Code and JSON only, as with prettier. The Markdown formatter would drop
// the trailing spaces that are line breaks.
"includes": [
"**/*.js",
"**/*.mjs",
"**/*.cjs",
"**/*.ts",
"**/*.mts",
"**/*.json",
"**/*.jsonc"
],
"indentStyle": "space",
"indentWidth": 2,
"lineEnding": "lf",
"lineWidth": 100
},
"javascript": {
// Biome reports `arguments` in ordinary methods as undeclared.
"globals": ["arguments"],
"formatter": {
"quoteStyle": "single",
"jsxQuoteStyle": "double",
"quoteProperties": "asNeeded",
"trailingCommas": "all",
"semicolons": "always",
"arrowParentheses": "always",
"bracketSpacing": true
}
},
"assist": { "enabled": true, "actions": { "source": { "organizeImports": "off" } } },
"linter": {
"enabled": true,
"rules": {
"preset": "recommended",
"correctness": {
// ESLint's no-undef, the one rule the ESLint config had.
"noUndeclaredVariables": "error",
// A function's arity matters here: mocha treats a `done` parameter as
// a callback test, and knex and objection look at `fn.length` too.
"noUnusedFunctionParameters": "off",
// TypeScript's noUnusedLocals takes this over as lib/ is converted.
"noUnusedVariables": "off"
},
"suspicious": {
// The files are CommonJS, where "use strict" is not redundant. Biome
// treats .js files as modules and its fix would remove it.
"noRedundantUseStrict": "off",
// The query builder is a thenable on purpose: `await Model.query()`.
"noThenProperty": "off",
// `x !== x` is the NaN check of SameValueZero (cloneDeep).
"noSelfCompare": "off",
// The loose comparisons are deliberate (ids compared across types),
// and the fix would change which values match.
"noDoubleEquals": "off",
// isNaN() and Number.isNaN() differ for non-numbers.
"noGlobalIsNan": "off",
// Local constants like `const toString = Object.prototype.toString`.
"noShadowRestrictedNames": "off",
// Mocha files register several hooks of the same kind on purpose.
"noDuplicateTestHooks": "off",
// The public typings and the type tests use `any` where it's meant.
"noExplicitAny": "off",
// Typings use `void` in union return types on purpose.
"noConfusingVoidType": "off",
// forEach callbacks written as `(x) => fn(x)` return a value, harmlessly.
"useIterableCallbackReturn": "off",
// A couple of `while ((m = re.exec(s)))` loops and lazy caches.
"noAssignInExpressions": "off",
// The parsers match control characters on purpose.
"noControlCharactersInRegex": "off",
// Type tests check declaration merging and implicit any on purpose.
"noUnsafeDeclarationMerging": "off",
"noImplicitAnyLet": "off",
// A test reassigns its model classes to check the related queries.
"noClassAssign": "off"
},
"complexity": {
// `this` in static methods is how Model subclasses work. The fix
// would replace it with the class name, which breaks inheritance.
"noThisInStatic": "off",
// `a && a.b` and `a?.b` differ when `a` is 0, '' or false.
"useOptionalChain": "off",
// `arguments` goes away as lib/ is converted to TypeScript.
"noArguments": "off",
// Style preferences, not bugs.
"useArrowFunction": "off",
"noUselessThisAlias": "off",
"noBannedTypes": "off",
"noStaticOnlyClass": "off"
},
"style": {
// Style preferences, not bugs.
"useTemplate": "off",
"useShorthandFunctionType": "off",
"noNonNullAssertion": "off"
},
"performance": {
// Two reduce() calls over a handful of items.
"noAccumulatingSpread": "off"
}
}
},
"overrides": [
{
// Generated by PEG.js from the .pegjs files.
"includes": ["src/queryBuilder/parsers/*Parser.js"],
"linter": { "enabled": false }
},
{
"includes": ["tests/**", "testUtils/**", "bench/**", "examples/**/tests.js"],
"javascript": {
"globals": [
"arguments",
"describe",
"it",
"before",
"after",
"beforeEach",
"afterEach",
"context"
]
}
}
]
}