@dvashim/biome-config 1.2.0 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +102 -102
- package/dist/{biome.react-balanced.json → biome.react-balanced.jsonc} +37 -3
- package/dist/{biome.react-recommended.json → biome.react-recommended.jsonc} +9 -1
- package/dist/{biome.react-strict.json → biome.react-strict.jsonc} +36 -2
- package/dist/{biome.recommended.json → biome.recommended.jsonc} +9 -1
- package/package.json +13 -13
package/README.md
CHANGED
|
@@ -83,140 +83,140 @@ React balanced configuration:
|
|
|
83
83
|
|
|
84
84
|
## Defaults
|
|
85
85
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
- attributePosition: `"auto"`
|
|
89
|
-
- bracketSameLine: `false`
|
|
90
|
-
- bracketSpacing: `true`
|
|
91
|
-
- expand: `"auto"`
|
|
92
|
-
- formatWithErrors: `false`
|
|
93
|
-
- indentStyle: `"space"`
|
|
94
|
-
- indentWidth: `2`
|
|
95
|
-
- lineEnding: `"lf"`
|
|
96
|
-
- lineWidth: `80`
|
|
97
|
-
- useEditorconfig: `true`
|
|
86
|
+
All configurations share the same base defaults.
|
|
98
87
|
|
|
99
|
-
###
|
|
88
|
+
### Schema
|
|
100
89
|
|
|
101
|
-
|
|
102
|
-
- jsxRuntime: `"transparent"`
|
|
90
|
+
`https://biomejs.dev/schemas/2.4.5/schema.json`
|
|
103
91
|
|
|
104
|
-
###
|
|
92
|
+
### Formatter
|
|
105
93
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
94
|
+
| Option | Value |
|
|
95
|
+
|--------|-------|
|
|
96
|
+
| attributePosition | `"auto"` |
|
|
97
|
+
| bracketSameLine | `false` |
|
|
98
|
+
| bracketSpacing | `true` |
|
|
99
|
+
| expand | `"auto"` |
|
|
100
|
+
| formatWithErrors | `false` |
|
|
101
|
+
| indentStyle | `"space"` |
|
|
102
|
+
| indentWidth | `2` |
|
|
103
|
+
| lineEnding | `"lf"` |
|
|
104
|
+
| lineWidth | `80` |
|
|
105
|
+
| useEditorconfig | `true` |
|
|
106
|
+
|
|
107
|
+
### JavaScript
|
|
108
|
+
|
|
109
|
+
| Option | Value |
|
|
110
|
+
|--------|-------|
|
|
111
|
+
| experimentalEmbeddedSnippetsEnabled | `true` |
|
|
112
|
+
| jsxRuntime | `"transparent"` |
|
|
113
|
+
|
|
114
|
+
### JavaScript Formatter
|
|
115
|
+
|
|
116
|
+
| Option | Value |
|
|
117
|
+
|--------|-------|
|
|
118
|
+
| arrowParentheses | `"always"` |
|
|
119
|
+
| jsxQuoteStyle | `"double"` |
|
|
120
|
+
| operatorLinebreak | `"before"` |
|
|
121
|
+
| quoteProperties | `"asNeeded"` |
|
|
122
|
+
| quoteStyle | `"single"` |
|
|
123
|
+
| semicolons | `"asNeeded"` |
|
|
124
|
+
| trailingCommas | `"es5"` |
|
|
125
|
+
|
|
126
|
+
### JSON
|
|
127
|
+
|
|
128
|
+
| Option | Value |
|
|
129
|
+
|--------|-------|
|
|
130
|
+
| allowComments | `true` |
|
|
131
|
+
| allowTrailingCommas | `true` |
|
|
132
|
+
|
|
133
|
+
### HTML
|
|
134
|
+
|
|
135
|
+
| Option | Value |
|
|
136
|
+
|--------|-------|
|
|
137
|
+
| experimentalFullSupportEnabled | `true` |
|
|
113
138
|
|
|
114
139
|
### Files
|
|
115
140
|
|
|
116
|
-
|
|
141
|
+
| Option | Value |
|
|
142
|
+
|--------|-------|
|
|
143
|
+
| includes | `["**", "!!**/dist"]` |
|
|
117
144
|
|
|
118
145
|
### VCS
|
|
119
146
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
147
|
+
| Option | Value |
|
|
148
|
+
|--------|-------|
|
|
149
|
+
| clientKind | `"git"` |
|
|
150
|
+
| defaultBranch | `"main"` |
|
|
151
|
+
| useIgnoreFile | `true` |
|
|
123
152
|
|
|
124
153
|
### Assist
|
|
125
154
|
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
### Schema
|
|
132
|
-
|
|
133
|
-
- `https://biomejs.dev/schemas/2.4.0/schema.json`
|
|
155
|
+
| Option | Value |
|
|
156
|
+
|--------|-------|
|
|
157
|
+
| actions.recommended | `true` |
|
|
158
|
+
| actions.source.noDuplicateClasses | `"on"` |
|
|
134
159
|
|
|
135
160
|
## Rules
|
|
136
161
|
|
|
137
|
-
### Base recommended
|
|
138
|
-
|
|
139
|
-
This configuration provides a base setup for linting, formatting, and code consistency across JavaScript, JSX, JSON, and HTML files. Key features include:
|
|
140
|
-
|
|
141
|
-
- **Linter Rules**
|
|
142
|
-
|
|
143
|
-
- Enables all **recommended Biome rules**, providing sensible defaults for code quality, correctness, and best practices without custom overrides.
|
|
144
|
-
|
|
145
|
-
- **Formatting:**
|
|
146
|
-
|
|
147
|
-
- Enforces consistent code style across JavaScript, JSX, JSON, and HTML, including indentation, bracket spacing, quote style, trailing commas, and line width.
|
|
148
|
-
- Supports editorconfig integration to maintain consistent formatting across editors.
|
|
149
|
-
|
|
150
|
-
- **Assist & Automation:**
|
|
151
|
-
|
|
152
|
-
- Enables **recommended automated actions** to streamline development and improve productivity.
|
|
162
|
+
### Base recommended
|
|
153
163
|
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
- Supports Git with `.gitignore` usage and sets `main` as the default branch.
|
|
157
|
-
|
|
158
|
-
- **File Management:**
|
|
159
|
-
|
|
160
|
-
- Includes all project files by default, excluding distribution directories.
|
|
164
|
+
Enables all **recommended Biome rules** out of the box with no custom overrides. Provides sensible defaults for code quality, correctness, and best practices across JavaScript, JSX, JSON, and HTML.
|
|
161
165
|
|
|
162
166
|
---
|
|
163
167
|
|
|
164
|
-
### React recommended
|
|
165
|
-
|
|
166
|
-
This configuration provides setup for linting, formatting, and code consistency across JavaScript, JSX, JSON, and HTML files, optimized for React projects. Key features include:
|
|
167
|
-
|
|
168
|
-
- **Linter Rules**
|
|
169
|
-
|
|
170
|
-
- **React Domain:** Applies recommended linting rules for React applications.
|
|
171
|
-
- **General:** Enables all recommended rules for consistent and safe coding practices.
|
|
172
|
-
|
|
173
|
-
- **Formatting:**
|
|
168
|
+
### React recommended
|
|
174
169
|
|
|
175
|
-
|
|
176
|
-
- Supports JavaScript, JSX, JSON, and HTML with editorconfig integration.
|
|
177
|
-
|
|
178
|
-
- **Assist & Automation:**
|
|
179
|
-
|
|
180
|
-
- Enables recommended automated actions to improve developer productivity.
|
|
181
|
-
|
|
182
|
-
- **Version Control (VCS):**
|
|
183
|
-
|
|
184
|
-
- Supports Git with `.gitignore` usage and sets `main` as the default branch.
|
|
185
|
-
|
|
186
|
-
- **File Management:**
|
|
187
|
-
|
|
188
|
-
- Includes all project files by default, excluding distribution directories.
|
|
170
|
+
Same as base recommended, plus enables the **React domain** (`"react": "recommended"`), which activates React-specific recommended rules for hooks, JSX, and component patterns.
|
|
189
171
|
|
|
190
172
|
---
|
|
191
173
|
|
|
192
|
-
### React strict
|
|
174
|
+
### React strict
|
|
193
175
|
|
|
194
|
-
|
|
176
|
+
The most opinionated configuration. Enables all recommended rules plus **120+ optional and nursery rules** across 8 categories. Every non-recommended JS/TS rule available in Biome is explicitly configured.
|
|
195
177
|
|
|
196
|
-
- **
|
|
178
|
+
- **a11y** — Selectively disables noisy rules (`useButtonType`, `useKeyWithClickEvents`, `useSemanticElements`, `noStaticElementInteractions`, `noNoninteractiveElementToInteractiveRole`) while keeping the rest at recommended defaults.
|
|
197
179
|
|
|
198
|
-
|
|
199
|
-
- **Complexity:** Monitors cognitive complexity, function length, nested test suites, and logic expressions to maintain readable code.
|
|
200
|
-
- **Correctness:** Ensures no undeclared variables, safe usage of globals, and proper React patterns.
|
|
201
|
-
- **Nursery / Best Practices:** Detects deprecated imports, floating promises, JSX issues, unused expressions, and enforces safer coding patterns.
|
|
202
|
-
- **Performance:** Highlights potential runtime inefficiencies (e.g., `await` in loops, barrel files, `delete` usage).
|
|
203
|
-
- **Security:** Warns on accidental inclusion of secrets in code.
|
|
204
|
-
- **Style & Consistency:** Enforces consistent syntax, naming conventions, array/object patterns, TypeScript typings, and React best practices.
|
|
205
|
-
- **Suspicious / Error-Prone Patterns:** Flags `var` usage, console calls, bitwise operators, empty blocks, and other potentially problematic constructs.
|
|
180
|
+
- **complexity** (12 rules) — Monitors cognitive complexity, function length, nested test suites, and logic expressions. Warns on `forEach`, implicit coercions, `void`, and useless patterns.
|
|
206
181
|
|
|
207
|
-
- **
|
|
182
|
+
- **correctness** (12 rules) — Ensures no undeclared variables/dependencies/imports, proper React patterns (`noReactPropAssignments`, `noNestedComponentDefinitions`), Node.js guards (`noNodejsModules`, `noProcessGlobal`, `noGlobalDirnameFilename`), and JSON import attributes.
|
|
208
183
|
|
|
209
|
-
|
|
210
|
-
-
|
|
184
|
+
- **nursery** (63 rules) — Opts into all experimental rules. Highlights include:
|
|
185
|
+
- **Errors:** `noJsxPropsBind`, `noLeakedRender`, `noMisusedPromises`, `noMultiAssign`, `noParametersOnlyUsedInRecursion`
|
|
186
|
+
- **Promises:** `noFloatingPromises`, `noNestedPromises`, `useAwaitThenable`
|
|
187
|
+
- **TypeScript:** `useConsistentEnumValueType`, `useConsistentMethodSignatures`, `useExhaustiveSwitchCases`, `useNullishCoalescing`
|
|
188
|
+
- **Regex:** `useNamedCaptureGroup`, `useUnicodeRegex`, `useRegexpExec`
|
|
189
|
+
- **Playwright:** Full suite of 10 Playwright rules
|
|
190
|
+
- **Tailwind:** `useSortedClasses`, `noFloatingClasses`
|
|
191
|
+
- **Disabled:** `noTernary`, `useExplicitType`
|
|
211
192
|
|
|
212
|
-
- **
|
|
193
|
+
- **performance** (6 rules) — Warns on `await` in loops, barrel files, `delete`, namespace imports, re-export all, and non-top-level regex.
|
|
213
194
|
|
|
214
|
-
|
|
195
|
+
- **security** — `noSecrets`
|
|
215
196
|
|
|
216
|
-
- **
|
|
197
|
+
- **style** (44 rules) — Enforces consistent syntax, naming conventions (`strictCase: true`), array shorthand syntax, `type` over `interface`, React function components, readonly class properties, `noDefaultExport`, `noMagicNumbers`, `noJsxLiterals`, and more.
|
|
217
198
|
|
|
218
|
-
|
|
199
|
+
- **suspicious** (22 rules) — Flags `var` (error), `console`, `alert`, bitwise operators, empty blocks, import cycles, evolving types, skipped tests, and deprecated imports.
|
|
219
200
|
|
|
220
|
-
|
|
201
|
+
---
|
|
221
202
|
|
|
222
|
-
|
|
203
|
+
### React balanced
|
|
204
|
+
|
|
205
|
+
Same rule set as strict, with **targeted relaxations** to reduce false positives and noise in real-world projects:
|
|
206
|
+
|
|
207
|
+
| Rule | Strict | Balanced | Reason |
|
|
208
|
+
|------|--------|----------|--------|
|
|
209
|
+
| `noImplicitCoercions` | warn | off | Too noisy with `!!value` patterns |
|
|
210
|
+
| `noExcessiveLinesPerFunction` | warn (default) | warn (maxLines: 100) | Higher threshold |
|
|
211
|
+
| `noContinue` | warn | info | Informational only |
|
|
212
|
+
| `noIncrementDecrement` | warn | warn (allowForLoopAfterthoughts) | Allows `i++` in for loops |
|
|
213
|
+
| `noUselessReturn` | warn | info | Informational only |
|
|
214
|
+
| `noBarrelFile` | warn | off | Common pattern in libraries |
|
|
215
|
+
| `noNamespaceImport` | warn | off | Allows `import * as` |
|
|
216
|
+
| `noReExportAll` | warn | off | Common pattern in libraries |
|
|
217
|
+
| `noDefaultExport` | warn | off | Allows default exports |
|
|
218
|
+
| `noImplicitBoolean` | warn | info | Informational only |
|
|
219
|
+
| `noJsxLiterals` | warn | off | Allows inline text in JSX |
|
|
220
|
+
| `noMagicNumbers` | warn | info | Informational only |
|
|
221
|
+
| `noNestedTernary` | warn | off | Allows nested ternaries |
|
|
222
|
+
| `useNamingConvention` | strictCase: true | strictCase: false | More lenient casing |
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://biomejs.dev/schemas/2.4.
|
|
2
|
+
"$schema": "https://biomejs.dev/schemas/2.4.5/schema.json",
|
|
3
3
|
|
|
4
|
+
// MARK: assist
|
|
4
5
|
"assist": {
|
|
5
6
|
"actions": {
|
|
6
7
|
"recommended": true,
|
|
@@ -10,10 +11,12 @@
|
|
|
10
11
|
}
|
|
11
12
|
},
|
|
12
13
|
|
|
14
|
+
// MARK: files
|
|
13
15
|
"files": {
|
|
14
16
|
"includes": ["**", "!!**/dist"]
|
|
15
17
|
},
|
|
16
18
|
|
|
19
|
+
// MARK: formatter
|
|
17
20
|
"formatter": {
|
|
18
21
|
"attributePosition": "auto",
|
|
19
22
|
"bracketSameLine": false,
|
|
@@ -27,10 +30,12 @@
|
|
|
27
30
|
"useEditorconfig": true
|
|
28
31
|
},
|
|
29
32
|
|
|
33
|
+
// MARK: html
|
|
30
34
|
"html": {
|
|
31
35
|
"experimentalFullSupportEnabled": true
|
|
32
36
|
},
|
|
33
37
|
|
|
38
|
+
// MARK: javascript
|
|
34
39
|
"javascript": {
|
|
35
40
|
"experimentalEmbeddedSnippetsEnabled": true,
|
|
36
41
|
"globals": [],
|
|
@@ -51,6 +56,7 @@
|
|
|
51
56
|
}
|
|
52
57
|
},
|
|
53
58
|
|
|
59
|
+
// MARK: json
|
|
54
60
|
"json": {
|
|
55
61
|
"parser": {
|
|
56
62
|
"allowComments": true,
|
|
@@ -58,8 +64,10 @@
|
|
|
58
64
|
}
|
|
59
65
|
},
|
|
60
66
|
|
|
67
|
+
// MARK: linter
|
|
61
68
|
"linter": {
|
|
62
69
|
"rules": {
|
|
70
|
+
// MARK: a11y
|
|
63
71
|
"a11y": {
|
|
64
72
|
"noNoninteractiveElementToInteractiveRole": "off",
|
|
65
73
|
"noStaticElementInteractions": "off",
|
|
@@ -68,6 +76,7 @@
|
|
|
68
76
|
"useKeyWithClickEvents": "off",
|
|
69
77
|
"useSemanticElements": "off"
|
|
70
78
|
},
|
|
79
|
+
// MARK: complexity
|
|
71
80
|
"complexity": {
|
|
72
81
|
"noExcessiveCognitiveComplexity": "warn",
|
|
73
82
|
"noExcessiveNestedTestSuites": "warn",
|
|
@@ -87,6 +96,7 @@
|
|
|
87
96
|
}
|
|
88
97
|
}
|
|
89
98
|
},
|
|
99
|
+
// MARK: correctness
|
|
90
100
|
"correctness": {
|
|
91
101
|
"noGlobalDirnameFilename": "warn",
|
|
92
102
|
"noNestedComponentDefinitions": "warn",
|
|
@@ -95,14 +105,16 @@
|
|
|
95
105
|
"noReactPropAssignments": "warn",
|
|
96
106
|
"noUndeclaredDependencies": "warn",
|
|
97
107
|
"noUndeclaredVariables": "warn",
|
|
98
|
-
"noUnresolvedImports": "
|
|
108
|
+
"noUnresolvedImports": "warn",
|
|
99
109
|
"useImportExtensions": "off",
|
|
100
110
|
"useJsonImportAttributes": "warn",
|
|
101
111
|
"useSingleJsDocAsterisk": "warn",
|
|
102
112
|
"useUniqueElementIds": "warn"
|
|
103
113
|
},
|
|
114
|
+
// MARK: nursery
|
|
104
115
|
"nursery": {
|
|
105
116
|
"noAmbiguousAnchorText": "warn",
|
|
117
|
+
"noConditionalExpect": "warn",
|
|
106
118
|
"noContinue": "info",
|
|
107
119
|
"noDivRegex": "warn",
|
|
108
120
|
"noDuplicateAttributes": "warn",
|
|
@@ -122,6 +134,16 @@
|
|
|
122
134
|
"noMultiStr": "error",
|
|
123
135
|
"noNestedPromises": "warn",
|
|
124
136
|
"noParametersOnlyUsedInRecursion": "error",
|
|
137
|
+
"noPlaywrightElementHandle": "warn",
|
|
138
|
+
"noPlaywrightEval": "warn",
|
|
139
|
+
"noPlaywrightForceOption": "warn",
|
|
140
|
+
"noPlaywrightMissingAwait": "warn",
|
|
141
|
+
"noPlaywrightNetworkidle": "warn",
|
|
142
|
+
"noPlaywrightPagePause": "warn",
|
|
143
|
+
"noPlaywrightUselessAwait": "warn",
|
|
144
|
+
"noPlaywrightWaitForNavigation": "warn",
|
|
145
|
+
"noPlaywrightWaitForSelector": "warn",
|
|
146
|
+
"noPlaywrightWaitForTimeout": "warn",
|
|
125
147
|
"noProto": "warn",
|
|
126
148
|
"noRedundantDefaultExport": "warn",
|
|
127
149
|
"noReturnAssign": "warn",
|
|
@@ -133,6 +155,7 @@
|
|
|
133
155
|
"noUnknownAttribute": "warn",
|
|
134
156
|
"noUnnecessaryConditions": "warn",
|
|
135
157
|
"noUselessReturn": "info",
|
|
158
|
+
"useArraySome": "warn",
|
|
136
159
|
"useArraySortCompare": "warn",
|
|
137
160
|
"useAwaitThenable": "warn",
|
|
138
161
|
"useConsistentEnumValueType": "warn",
|
|
@@ -140,11 +163,17 @@
|
|
|
140
163
|
"useDestructuring": "warn",
|
|
141
164
|
"useErrorCause": "warn",
|
|
142
165
|
"useExhaustiveSwitchCases": "warn",
|
|
166
|
+
"useExpect": "warn",
|
|
143
167
|
"useExplicitType": "off",
|
|
144
168
|
"useFind": "warn",
|
|
145
169
|
"useGlobalThis": "warn",
|
|
170
|
+
"useNamedCaptureGroup": "warn",
|
|
171
|
+
"useNullishCoalescing": "warn",
|
|
172
|
+
"usePlaywrightValidDescribeCallback": "warn",
|
|
146
173
|
"useRegexpExec": "warn",
|
|
174
|
+
"useSortedClasses": "warn",
|
|
147
175
|
"useSpread": "warn",
|
|
176
|
+
"useUnicodeRegex": "warn",
|
|
148
177
|
"noIncrementDecrement": {
|
|
149
178
|
"level": "warn",
|
|
150
179
|
"options": {
|
|
@@ -152,6 +181,7 @@
|
|
|
152
181
|
}
|
|
153
182
|
}
|
|
154
183
|
},
|
|
184
|
+
// MARK: performance
|
|
155
185
|
"performance": {
|
|
156
186
|
"noAwaitInLoops": "warn",
|
|
157
187
|
"noBarrelFile": "off",
|
|
@@ -160,9 +190,11 @@
|
|
|
160
190
|
"noReExportAll": "off",
|
|
161
191
|
"useTopLevelRegex": "warn"
|
|
162
192
|
},
|
|
193
|
+
// MARK: security
|
|
163
194
|
"security": {
|
|
164
195
|
"noSecrets": "warn"
|
|
165
196
|
},
|
|
197
|
+
// MARK: style
|
|
166
198
|
"style": {
|
|
167
199
|
"noCommonJs": "warn",
|
|
168
200
|
"noDefaultExport": "off",
|
|
@@ -172,7 +204,7 @@
|
|
|
172
204
|
"noImplicitBoolean": "info",
|
|
173
205
|
"noInferrableTypes": "warn",
|
|
174
206
|
"noJsxLiterals": "off",
|
|
175
|
-
"noMagicNumbers": "
|
|
207
|
+
"noMagicNumbers": "info",
|
|
176
208
|
"noNamespace": "warn",
|
|
177
209
|
"noNegationElse": "warn",
|
|
178
210
|
"noNestedTernary": "off",
|
|
@@ -237,6 +269,7 @@
|
|
|
237
269
|
}
|
|
238
270
|
}
|
|
239
271
|
},
|
|
272
|
+
// MARK: suspicious
|
|
240
273
|
"suspicious": {
|
|
241
274
|
"noAlert": "warn",
|
|
242
275
|
"noBitwiseOperators": "warn",
|
|
@@ -264,6 +297,7 @@
|
|
|
264
297
|
}
|
|
265
298
|
},
|
|
266
299
|
|
|
300
|
+
// MARK: vcs
|
|
267
301
|
"vcs": {
|
|
268
302
|
"clientKind": "git",
|
|
269
303
|
"defaultBranch": "main",
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://biomejs.dev/schemas/2.4.
|
|
2
|
+
"$schema": "https://biomejs.dev/schemas/2.4.5/schema.json",
|
|
3
3
|
|
|
4
|
+
// MARK: assist
|
|
4
5
|
"assist": {
|
|
5
6
|
"actions": {
|
|
6
7
|
"recommended": true,
|
|
@@ -10,10 +11,12 @@
|
|
|
10
11
|
}
|
|
11
12
|
},
|
|
12
13
|
|
|
14
|
+
// MARK: files
|
|
13
15
|
"files": {
|
|
14
16
|
"includes": ["**", "!!**/dist"]
|
|
15
17
|
},
|
|
16
18
|
|
|
19
|
+
// MARK: formatter
|
|
17
20
|
"formatter": {
|
|
18
21
|
"attributePosition": "auto",
|
|
19
22
|
"bracketSameLine": false,
|
|
@@ -27,10 +30,12 @@
|
|
|
27
30
|
"useEditorconfig": true
|
|
28
31
|
},
|
|
29
32
|
|
|
33
|
+
// MARK: html
|
|
30
34
|
"html": {
|
|
31
35
|
"experimentalFullSupportEnabled": true
|
|
32
36
|
},
|
|
33
37
|
|
|
38
|
+
// MARK: javascript
|
|
34
39
|
"javascript": {
|
|
35
40
|
"experimentalEmbeddedSnippetsEnabled": true,
|
|
36
41
|
"globals": [],
|
|
@@ -51,6 +56,7 @@
|
|
|
51
56
|
}
|
|
52
57
|
},
|
|
53
58
|
|
|
59
|
+
// MARK: json
|
|
54
60
|
"json": {
|
|
55
61
|
"parser": {
|
|
56
62
|
"allowComments": true,
|
|
@@ -58,6 +64,7 @@
|
|
|
58
64
|
}
|
|
59
65
|
},
|
|
60
66
|
|
|
67
|
+
// MARK: linter
|
|
61
68
|
"linter": {
|
|
62
69
|
"domains": {
|
|
63
70
|
"react": "recommended"
|
|
@@ -67,6 +74,7 @@
|
|
|
67
74
|
}
|
|
68
75
|
},
|
|
69
76
|
|
|
77
|
+
// MARK: vcs
|
|
70
78
|
"vcs": {
|
|
71
79
|
"clientKind": "git",
|
|
72
80
|
"defaultBranch": "main",
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://biomejs.dev/schemas/2.4.
|
|
2
|
+
"$schema": "https://biomejs.dev/schemas/2.4.5/schema.json",
|
|
3
3
|
|
|
4
|
+
// MARK: assist
|
|
4
5
|
"assist": {
|
|
5
6
|
"actions": {
|
|
6
7
|
"recommended": true,
|
|
@@ -10,10 +11,12 @@
|
|
|
10
11
|
}
|
|
11
12
|
},
|
|
12
13
|
|
|
14
|
+
// MARK: files
|
|
13
15
|
"files": {
|
|
14
16
|
"includes": ["**", "!!**/dist"]
|
|
15
17
|
},
|
|
16
18
|
|
|
19
|
+
// MARK: formatter
|
|
17
20
|
"formatter": {
|
|
18
21
|
"attributePosition": "auto",
|
|
19
22
|
"bracketSameLine": false,
|
|
@@ -27,10 +30,12 @@
|
|
|
27
30
|
"useEditorconfig": true
|
|
28
31
|
},
|
|
29
32
|
|
|
33
|
+
// MARK: html
|
|
30
34
|
"html": {
|
|
31
35
|
"experimentalFullSupportEnabled": true
|
|
32
36
|
},
|
|
33
37
|
|
|
38
|
+
// MARK: javascript
|
|
34
39
|
"javascript": {
|
|
35
40
|
"experimentalEmbeddedSnippetsEnabled": true,
|
|
36
41
|
"globals": [],
|
|
@@ -51,6 +56,7 @@
|
|
|
51
56
|
}
|
|
52
57
|
},
|
|
53
58
|
|
|
59
|
+
// MARK: json
|
|
54
60
|
"json": {
|
|
55
61
|
"parser": {
|
|
56
62
|
"allowComments": true,
|
|
@@ -58,8 +64,10 @@
|
|
|
58
64
|
}
|
|
59
65
|
},
|
|
60
66
|
|
|
67
|
+
// MARK: linter
|
|
61
68
|
"linter": {
|
|
62
69
|
"rules": {
|
|
70
|
+
// MARK: a11y
|
|
63
71
|
"a11y": {
|
|
64
72
|
"noNoninteractiveElementToInteractiveRole": "off",
|
|
65
73
|
"noStaticElementInteractions": "off",
|
|
@@ -68,6 +76,7 @@
|
|
|
68
76
|
"useKeyWithClickEvents": "off",
|
|
69
77
|
"useSemanticElements": "off"
|
|
70
78
|
},
|
|
79
|
+
// MARK: complexity
|
|
71
80
|
"complexity": {
|
|
72
81
|
"noExcessiveCognitiveComplexity": "warn",
|
|
73
82
|
"noExcessiveLinesPerFunction": "warn",
|
|
@@ -82,6 +91,7 @@
|
|
|
82
91
|
"useSimplifiedLogicExpression": "warn",
|
|
83
92
|
"useWhile": "warn"
|
|
84
93
|
},
|
|
94
|
+
// MARK: correctness
|
|
85
95
|
"correctness": {
|
|
86
96
|
"noGlobalDirnameFilename": "warn",
|
|
87
97
|
"noNestedComponentDefinitions": "warn",
|
|
@@ -96,8 +106,10 @@
|
|
|
96
106
|
"useSingleJsDocAsterisk": "warn",
|
|
97
107
|
"useUniqueElementIds": "warn"
|
|
98
108
|
},
|
|
109
|
+
// MARK: nursery
|
|
99
110
|
"nursery": {
|
|
100
111
|
"noAmbiguousAnchorText": "warn",
|
|
112
|
+
"noConditionalExpect": "warn",
|
|
101
113
|
"noContinue": "warn",
|
|
102
114
|
"noDivRegex": "warn",
|
|
103
115
|
"noDuplicateAttributes": "warn",
|
|
@@ -118,6 +130,16 @@
|
|
|
118
130
|
"noMultiStr": "error",
|
|
119
131
|
"noNestedPromises": "warn",
|
|
120
132
|
"noParametersOnlyUsedInRecursion": "error",
|
|
133
|
+
"noPlaywrightElementHandle": "warn",
|
|
134
|
+
"noPlaywrightEval": "warn",
|
|
135
|
+
"noPlaywrightForceOption": "warn",
|
|
136
|
+
"noPlaywrightMissingAwait": "warn",
|
|
137
|
+
"noPlaywrightNetworkidle": "warn",
|
|
138
|
+
"noPlaywrightPagePause": "warn",
|
|
139
|
+
"noPlaywrightUselessAwait": "warn",
|
|
140
|
+
"noPlaywrightWaitForNavigation": "warn",
|
|
141
|
+
"noPlaywrightWaitForSelector": "warn",
|
|
142
|
+
"noPlaywrightWaitForTimeout": "warn",
|
|
121
143
|
"noProto": "warn",
|
|
122
144
|
"noRedundantDefaultExport": "warn",
|
|
123
145
|
"noReturnAssign": "warn",
|
|
@@ -129,6 +151,7 @@
|
|
|
129
151
|
"noUnknownAttribute": "warn",
|
|
130
152
|
"noUnnecessaryConditions": "warn",
|
|
131
153
|
"noUselessReturn": "warn",
|
|
154
|
+
"useArraySome": "warn",
|
|
132
155
|
"useArraySortCompare": "warn",
|
|
133
156
|
"useAwaitThenable": "warn",
|
|
134
157
|
"useConsistentEnumValueType": "warn",
|
|
@@ -136,12 +159,19 @@
|
|
|
136
159
|
"useDestructuring": "warn",
|
|
137
160
|
"useErrorCause": "warn",
|
|
138
161
|
"useExhaustiveSwitchCases": "warn",
|
|
162
|
+
"useExpect": "warn",
|
|
139
163
|
"useExplicitType": "off",
|
|
140
164
|
"useFind": "warn",
|
|
141
165
|
"useGlobalThis": "warn",
|
|
166
|
+
"useNamedCaptureGroup": "warn",
|
|
167
|
+
"useNullishCoalescing": "warn",
|
|
168
|
+
"usePlaywrightValidDescribeCallback": "warn",
|
|
142
169
|
"useRegexpExec": "warn",
|
|
143
|
-
"
|
|
170
|
+
"useSortedClasses": "warn",
|
|
171
|
+
"useSpread": "warn",
|
|
172
|
+
"useUnicodeRegex": "warn"
|
|
144
173
|
},
|
|
174
|
+
// MARK: performance
|
|
145
175
|
"performance": {
|
|
146
176
|
"noAwaitInLoops": "warn",
|
|
147
177
|
"noBarrelFile": "warn",
|
|
@@ -150,9 +180,11 @@
|
|
|
150
180
|
"noReExportAll": "warn",
|
|
151
181
|
"useTopLevelRegex": "warn"
|
|
152
182
|
},
|
|
183
|
+
// MARK: security
|
|
153
184
|
"security": {
|
|
154
185
|
"noSecrets": "warn"
|
|
155
186
|
},
|
|
187
|
+
// MARK: style
|
|
156
188
|
"style": {
|
|
157
189
|
"noCommonJs": "warn",
|
|
158
190
|
"noDefaultExport": "warn",
|
|
@@ -227,6 +259,7 @@
|
|
|
227
259
|
}
|
|
228
260
|
}
|
|
229
261
|
},
|
|
262
|
+
// MARK: suspicious
|
|
230
263
|
"suspicious": {
|
|
231
264
|
"noAlert": "warn",
|
|
232
265
|
"noBitwiseOperators": "warn",
|
|
@@ -254,6 +287,7 @@
|
|
|
254
287
|
}
|
|
255
288
|
},
|
|
256
289
|
|
|
290
|
+
// MARK: vcs
|
|
257
291
|
"vcs": {
|
|
258
292
|
"clientKind": "git",
|
|
259
293
|
"defaultBranch": "main",
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://biomejs.dev/schemas/2.4.
|
|
2
|
+
"$schema": "https://biomejs.dev/schemas/2.4.5/schema.json",
|
|
3
3
|
|
|
4
|
+
// MARK: assist
|
|
4
5
|
"assist": {
|
|
5
6
|
"actions": {
|
|
6
7
|
"recommended": true,
|
|
@@ -10,10 +11,12 @@
|
|
|
10
11
|
}
|
|
11
12
|
},
|
|
12
13
|
|
|
14
|
+
// MARK: files
|
|
13
15
|
"files": {
|
|
14
16
|
"includes": ["**", "!!**/dist"]
|
|
15
17
|
},
|
|
16
18
|
|
|
19
|
+
// MARK: formatter
|
|
17
20
|
"formatter": {
|
|
18
21
|
"attributePosition": "auto",
|
|
19
22
|
"bracketSameLine": false,
|
|
@@ -27,10 +30,12 @@
|
|
|
27
30
|
"useEditorconfig": true
|
|
28
31
|
},
|
|
29
32
|
|
|
33
|
+
// MARK: html
|
|
30
34
|
"html": {
|
|
31
35
|
"experimentalFullSupportEnabled": true
|
|
32
36
|
},
|
|
33
37
|
|
|
38
|
+
// MARK: javascript
|
|
34
39
|
"javascript": {
|
|
35
40
|
"experimentalEmbeddedSnippetsEnabled": true,
|
|
36
41
|
"globals": [],
|
|
@@ -51,6 +56,7 @@
|
|
|
51
56
|
}
|
|
52
57
|
},
|
|
53
58
|
|
|
59
|
+
// MARK: json
|
|
54
60
|
"json": {
|
|
55
61
|
"parser": {
|
|
56
62
|
"allowComments": true,
|
|
@@ -58,12 +64,14 @@
|
|
|
58
64
|
}
|
|
59
65
|
},
|
|
60
66
|
|
|
67
|
+
// MARK: linter
|
|
61
68
|
"linter": {
|
|
62
69
|
"rules": {
|
|
63
70
|
"recommended": true
|
|
64
71
|
}
|
|
65
72
|
},
|
|
66
73
|
|
|
74
|
+
// MARK: vcs
|
|
67
75
|
"vcs": {
|
|
68
76
|
"clientKind": "git",
|
|
69
77
|
"defaultBranch": "main",
|
package/package.json
CHANGED
|
@@ -3,26 +3,26 @@
|
|
|
3
3
|
"license": "MIT",
|
|
4
4
|
"name": "@dvashim/biome-config",
|
|
5
5
|
"type": "module",
|
|
6
|
-
"version": "1.
|
|
6
|
+
"version": "1.3.0",
|
|
7
7
|
"author": {
|
|
8
8
|
"email": "aleksei@dvashim.dev",
|
|
9
9
|
"name": "Aleksei Reznichenko"
|
|
10
10
|
},
|
|
11
11
|
"devDependencies": {
|
|
12
|
-
"@biomejs/biome": "^2.4.
|
|
13
|
-
"@changesets/changelog-github": "^0.
|
|
14
|
-
"@changesets/cli": "^2.
|
|
15
|
-
"validate-package-exports": "^0.
|
|
12
|
+
"@biomejs/biome": "^2.4.5",
|
|
13
|
+
"@changesets/changelog-github": "^0.6.0",
|
|
14
|
+
"@changesets/cli": "^2.30.0",
|
|
15
|
+
"validate-package-exports": "^0.19.1"
|
|
16
16
|
},
|
|
17
17
|
"exports": {
|
|
18
|
-
".": "./dist/biome.recommended.
|
|
19
|
-
"./react-balanced": "./dist/biome.react-balanced.
|
|
20
|
-
"./react-recommended": "./dist/biome.react-recommended.
|
|
21
|
-
"./react-strict": "./dist/biome.react-strict.
|
|
22
|
-
"./react/balanced": "./dist/biome.react-balanced.
|
|
23
|
-
"./react/recommended": "./dist/biome.react-recommended.
|
|
24
|
-
"./react/strict": "./dist/biome.react-strict.
|
|
25
|
-
"./recommended": "./dist/biome.recommended.
|
|
18
|
+
".": "./dist/biome.recommended.jsonc",
|
|
19
|
+
"./react-balanced": "./dist/biome.react-balanced.jsonc",
|
|
20
|
+
"./react-recommended": "./dist/biome.react-recommended.jsonc",
|
|
21
|
+
"./react-strict": "./dist/biome.react-strict.jsonc",
|
|
22
|
+
"./react/balanced": "./dist/biome.react-balanced.jsonc",
|
|
23
|
+
"./react/recommended": "./dist/biome.react-recommended.jsonc",
|
|
24
|
+
"./react/strict": "./dist/biome.react-strict.jsonc",
|
|
25
|
+
"./recommended": "./dist/biome.recommended.jsonc"
|
|
26
26
|
},
|
|
27
27
|
"files": [
|
|
28
28
|
"dist"
|