@bratislava/eslint-config 0.5.2 → 0.7.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/index.js +12 -1
- package/package.json +3 -1
package/index.js
CHANGED
|
@@ -6,7 +6,9 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
import eslint from "@eslint/js";
|
|
9
|
+
import markdown from "@eslint/markdown";
|
|
9
10
|
import prettier from "eslint-config-prettier";
|
|
11
|
+
import importPlugin from "eslint-plugin-import";
|
|
10
12
|
import noUnsanitized from "eslint-plugin-no-unsanitized";
|
|
11
13
|
import security from "eslint-plugin-security";
|
|
12
14
|
import simpleImportSort from "eslint-plugin-simple-import-sort";
|
|
@@ -78,6 +80,7 @@ export const eslintRules = {
|
|
|
78
80
|
"default-param-last": "error",
|
|
79
81
|
"dot-notation": "error",
|
|
80
82
|
eqeqeq: ["error", "smart"],
|
|
83
|
+
"guard-for-in": "error",
|
|
81
84
|
"new-cap": ["error", { capIsNew: false }],
|
|
82
85
|
"no-caller": "error",
|
|
83
86
|
"no-div-regex": "error",
|
|
@@ -86,6 +89,7 @@ export const eslintRules = {
|
|
|
86
89
|
"no-invalid-this": "error",
|
|
87
90
|
"no-lonely-if": "error",
|
|
88
91
|
"no-param-reassign": "error",
|
|
92
|
+
"no-restricted-syntax": "error",
|
|
89
93
|
"no-return-assign": "error",
|
|
90
94
|
"no-unneeded-ternary": "error",
|
|
91
95
|
"no-unused-expressions": "error",
|
|
@@ -111,8 +115,9 @@ export const sonarjsRules = {
|
|
|
111
115
|
"sonarjs/no-useless-catch": "off",
|
|
112
116
|
"sonarjs/no-commented-code": "off",
|
|
113
117
|
"sonarjs/no-nested-conditional": "off",
|
|
118
|
+
"sonarjs/no-unused-vars": "off", // handled by @typescript-eslint/no-unused-vars
|
|
114
119
|
"sonarjs/fixme-tag": "warn",
|
|
115
|
-
"sonarjs/deprecation": "
|
|
120
|
+
"sonarjs/deprecation": "off", // handled by @typescript-eslint/no-deprecated
|
|
116
121
|
};
|
|
117
122
|
|
|
118
123
|
/**
|
|
@@ -140,6 +145,12 @@ export const baseConfig = [
|
|
|
140
145
|
security.configs.recommended,
|
|
141
146
|
noUnsanitized.configs.recommended,
|
|
142
147
|
sonarjs.configs.recommended,
|
|
148
|
+
...markdown.configs.recommended,
|
|
149
|
+
{
|
|
150
|
+
plugins: {
|
|
151
|
+
import: importPlugin,
|
|
152
|
+
},
|
|
153
|
+
},
|
|
143
154
|
{
|
|
144
155
|
languageOptions: {
|
|
145
156
|
parserOptions: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bratislava/eslint-config",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0",
|
|
4
4
|
"description": "Base ESLint configuration for Bratislava projects",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eslint",
|
|
@@ -29,7 +29,9 @@
|
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
31
|
"@eslint/js": "9.34.0",
|
|
32
|
+
"@eslint/markdown": "6.6.0",
|
|
32
33
|
"eslint-config-prettier": "10.1.8",
|
|
34
|
+
"eslint-plugin-import": "2.32.0",
|
|
33
35
|
"eslint-plugin-no-unsanitized": "4.1.4",
|
|
34
36
|
"eslint-plugin-security": "3.0.1",
|
|
35
37
|
"eslint-plugin-simple-import-sort": "12.1.1",
|