@viclafouch/eslint-config-viclafouch 4.17.1-beta.0 → 4.17.1-beta.2
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/package.json +3 -2
- package/prettier.mjs +1 -1
- package/rules/best-practices.mjs +1 -0
- package/rules/errors.mjs +1 -0
- package/rules/es6.mjs +6 -0
- package/rules/imports.mjs +1 -0
- package/rules/node.mjs +1 -0
- package/rules/style.mjs +1 -0
- package/rules/variables.mjs +8 -1
package/package.json
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@viclafouch/eslint-config-viclafouch",
|
|
3
|
-
"version": "4.17.1-beta.
|
|
3
|
+
"version": "4.17.1-beta.2",
|
|
4
4
|
"description": "ESLint and Prettier Config from Victor de la Fouchardiere",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"javascript",
|
|
8
8
|
"ecmascript",
|
|
9
|
+
"eslintconfig",
|
|
9
10
|
"typescript",
|
|
10
11
|
"eslint",
|
|
11
12
|
"config",
|
|
@@ -24,7 +25,7 @@
|
|
|
24
25
|
"license": "MIT",
|
|
25
26
|
"homepage": "https://github.com/viclafouch/eslint-config-viclafouch#readme",
|
|
26
27
|
"peerDependencies": {
|
|
27
|
-
"eslint": "
|
|
28
|
+
"eslint": ">= 9",
|
|
28
29
|
"prettier": "^3.4.2",
|
|
29
30
|
"typescript": "^5.7.2"
|
|
30
31
|
},
|
package/prettier.mjs
CHANGED
|
@@ -4,8 +4,8 @@ import eslintPluginPrettierRecommended from 'eslint-plugin-prettier/recommended'
|
|
|
4
4
|
* @type {import("eslint").Linter.Config}
|
|
5
5
|
*/
|
|
6
6
|
export default [
|
|
7
|
+
eslintPluginPrettierRecommended,
|
|
7
8
|
{
|
|
8
|
-
...eslintPluginPrettierRecommended,
|
|
9
9
|
rules: {
|
|
10
10
|
'prettier/prettier': [
|
|
11
11
|
'error',
|
package/rules/best-practices.mjs
CHANGED
package/rules/errors.mjs
CHANGED
package/rules/es6.mjs
CHANGED
|
@@ -4,10 +4,16 @@ import pluginPromise from 'eslint-plugin-promise'
|
|
|
4
4
|
* @type {import("eslint").Linter.Config}
|
|
5
5
|
*/
|
|
6
6
|
export default {
|
|
7
|
+
files: ['**/*.{js,mjs,cjs,jsx}'],
|
|
7
8
|
plugins: {
|
|
8
9
|
promise: pluginPromise
|
|
9
10
|
},
|
|
10
11
|
languageOptions: {
|
|
12
|
+
parserOptions: {
|
|
13
|
+
ecmaFeatures: {
|
|
14
|
+
jsx: true
|
|
15
|
+
}
|
|
16
|
+
},
|
|
11
17
|
ecmaVersion: 2022,
|
|
12
18
|
sourceType: 'module'
|
|
13
19
|
},
|
package/rules/imports.mjs
CHANGED
package/rules/node.mjs
CHANGED
package/rules/style.mjs
CHANGED
package/rules/variables.mjs
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
* @type {import("eslint").Linter.Config}
|
|
3
3
|
*/
|
|
4
4
|
export default {
|
|
5
|
+
files: ['**/*.{js,mjs,cjs,jsx}'],
|
|
5
6
|
rules: {
|
|
6
7
|
// enforce or disallow variable initializations at definition
|
|
7
8
|
'init-declarations': 'off',
|
|
@@ -63,7 +64,13 @@ export default {
|
|
|
63
64
|
// disallow declaration of variables that are not used in the code
|
|
64
65
|
'no-unused-vars': [
|
|
65
66
|
'error',
|
|
66
|
-
{
|
|
67
|
+
{
|
|
68
|
+
vars: 'all',
|
|
69
|
+
args: 'after-used',
|
|
70
|
+
caughtErrors: 'none',
|
|
71
|
+
argsIgnorePattern: '^_',
|
|
72
|
+
ignoreRestSiblings: true
|
|
73
|
+
}
|
|
67
74
|
],
|
|
68
75
|
|
|
69
76
|
// disallow use of variables before they are defined
|