@mikey-pro/eslint-config 8.0.6 → 8.0.8
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 +15 -8
- package/package.json +13 -4
package/index.js
CHANGED
|
@@ -7,7 +7,6 @@ import disableAutofix from 'eslint-plugin-disable-autofix';
|
|
|
7
7
|
import importPlugin from 'eslint-plugin-import';
|
|
8
8
|
import onlyWarn from 'eslint-plugin-only-warn';
|
|
9
9
|
import prettier from 'eslint-plugin-prettier';
|
|
10
|
-
import prettierRecommended from 'eslint-plugin-prettier/config/recommended';
|
|
11
10
|
import unicorn from 'eslint-plugin-unicorn';
|
|
12
11
|
import globals from 'globals';
|
|
13
12
|
import securityPlugin from 'eslint-plugin-security';
|
|
@@ -17,8 +16,8 @@ import perfectionistPlugin from 'eslint-plugin-perfectionist';
|
|
|
17
16
|
import noSecretsPlugin from 'eslint-plugin-no-secrets';
|
|
18
17
|
import noOnlyTestsPlugin from 'eslint-plugin-no-only-tests';
|
|
19
18
|
|
|
20
|
-
import { baseOverrides } from './overrides';
|
|
21
|
-
import { baseRules } from './rules';
|
|
19
|
+
import { baseOverrides } from './overrides.js';
|
|
20
|
+
import { baseRules } from './rules.js';
|
|
22
21
|
|
|
23
22
|
/** @type {import('eslint').Linter.Config[]} */
|
|
24
23
|
const config = [
|
|
@@ -91,7 +90,13 @@ const config = [
|
|
|
91
90
|
...compatPlugin.configs.recommended.rules,
|
|
92
91
|
...cssModules.configs.recommended.rules,
|
|
93
92
|
...importPlugin.configs.recommended.rules,
|
|
94
|
-
|
|
93
|
+
'prettier/prettier': ['warn', {
|
|
94
|
+
parser: 'babel',
|
|
95
|
+
endOfLine: 'lf',
|
|
96
|
+
singleQuote: true,
|
|
97
|
+
trailingComma: 'all'
|
|
98
|
+
}],
|
|
99
|
+
|
|
95
100
|
// Security
|
|
96
101
|
'security/detect-object-injection': 'warn',
|
|
97
102
|
'security/detect-possible-timing-attacks': 'warn',
|
|
@@ -132,6 +137,12 @@ const config = [
|
|
|
132
137
|
'import/parsers': {
|
|
133
138
|
'@typescript-eslint/parser': ['.ts', '.tsx', '.mts', '.cts'],
|
|
134
139
|
},
|
|
140
|
+
'import/extensions': ['.js', '.jsx', '.ts', '.tsx', '.mjs', '.cjs'],
|
|
141
|
+
'import/resolver': {
|
|
142
|
+
node: {
|
|
143
|
+
extensions: ['.js', '.jsx', '.ts', '.tsx', '.mjs', '.cjs']
|
|
144
|
+
}
|
|
145
|
+
},
|
|
135
146
|
},
|
|
136
147
|
},
|
|
137
148
|
...baseOverrides,
|
|
@@ -140,7 +151,3 @@ const config = [
|
|
|
140
151
|
export default config;
|
|
141
152
|
export { baseRules } from './rules.js';
|
|
142
153
|
export { baseOverrides } from './overrides.js';
|
|
143
|
-
|
|
144
|
-
if (typeof module !== 'undefined' && module.exports) {
|
|
145
|
-
module.exports = config;
|
|
146
|
-
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mikey-pro/eslint-config",
|
|
3
|
-
"version": "8.0.
|
|
3
|
+
"version": "8.0.8",
|
|
4
4
|
"description": "Mikey Pro ESLint configuration",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"types": "index.d.ts",
|
|
@@ -122,8 +122,17 @@
|
|
|
122
122
|
"yarn": ">=4.0.0"
|
|
123
123
|
},
|
|
124
124
|
"exports": {
|
|
125
|
-
".":
|
|
126
|
-
|
|
127
|
-
|
|
125
|
+
".": {
|
|
126
|
+
"import": "./index.js",
|
|
127
|
+
"require": "./index.js"
|
|
128
|
+
},
|
|
129
|
+
"./rules": {
|
|
130
|
+
"import": "./rules.js",
|
|
131
|
+
"require": "./rules.js"
|
|
132
|
+
},
|
|
133
|
+
"./overrides": {
|
|
134
|
+
"import": "./overrides.js",
|
|
135
|
+
"require": "./overrides.js"
|
|
136
|
+
}
|
|
128
137
|
}
|
|
129
138
|
}
|