-
Notifications
You must be signed in to change notification settings - Fork 57
Expand file tree
/
Copy patheslint.config.js
More file actions
48 lines (47 loc) · 1.46 KB
/
eslint.config.js
File metadata and controls
48 lines (47 loc) · 1.46 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
import { default as browserCompatibility } from "eslint-plugin-compat";
import jsdoc from "eslint-plugin-jsdoc";
export default [
// The below configuration ensures that code is compatible with the browser
// versions defined in the .browserslistrc file.
browserCompatibility.configs["flat/recommended"],
// The below configuration ensures that code is documented and that the
// documentation follows JSDoc formatting rules.
{
plugins: {
jsdoc,
},
ignores: [
"Universal-Federated-Analytics-Min.js"
],
rules: {
...jsdoc.configs.recommended.rules,
"jsdoc/check-indentation": "error",
"jsdoc/check-line-alignment": "error",
"jsdoc/check-syntax": "error",
"jsdoc/convert-to-jsdoc-comments": "error",
"jsdoc/no-bad-blocks": "error",
"jsdoc/no-blank-block-descriptions": "error",
"jsdoc/no-blank-blocks": "error",
"jsdoc/require-asterisk-prefix": "error",
"jsdoc/require-jsdoc": [
"error",
{
checkGetters: false,
checkSetters: false,
publicOnly: false,
require: {
ArrowFunctionExpression: true,
ClassDeclaration: true,
ClassExpression: true,
FunctionDeclaration: true,
FunctionExpression: true,
MethodDefinition: true,
},
},
],
"jsdoc/require-throws": "error",
"jsdoc/sort-tags": "error",
"jsdoc/tag-lines": "off",
},
},
];