@putout/eslint 3.5.0 → 3.6.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/lib/eslint.js CHANGED
@@ -14,7 +14,6 @@ const noESLint = process.env.NO_ESLINT;
14
14
  const noESLintWarnings = process.env.NO_ESLINT_WARNINGS;
15
15
 
16
16
  const NO_FLAT_CONFIG_FOUND = 'Could not find config file.';
17
-
18
17
  const WARNING = 1;
19
18
 
20
19
  const noConfigFound = (config, configError) => {
@@ -27,6 +26,12 @@ const noConfigFound = (config, configError) => {
27
26
  if (configError)
28
27
  return false;
29
28
 
29
+ if (!config)
30
+ return true;
31
+
32
+ if (!config.rules)
33
+ return true;
34
+
30
35
  return !keys(config.rules).length;
31
36
  };
32
37
 
@@ -1,7 +1,7 @@
1
1
  import {dirname} from 'node:path';
2
+ import process from 'node:process';
2
3
  import {loadESLint} from 'eslint';
3
4
  import {findUp} from 'find-up';
4
- import process from 'node:process';
5
5
 
6
6
  const CWD = process.cwd();
7
7
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@putout/eslint",
3
- "version": "3.5.0",
3
+ "version": "3.6.0",
4
4
  "type": "commonjs",
5
5
  "author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",
6
6
  "description": "Wrapper that simplifies ESLint API and makes it compatible with 🐊Putout",
@@ -38,11 +38,10 @@
38
38
  ],
39
39
  "devDependencies": {
40
40
  "@putout/plugin-eslint-plugin": "*",
41
- "c8": "^9.0.0",
41
+ "c8": "^10.0.0",
42
42
  "eslint": "^9.0.0",
43
43
  "eslint-plugin-n": "^17.0.0",
44
- "eslint-plugin-putout": "^22.0.0",
45
- "just-camel-case": "^4.0.2",
44
+ "eslint-plugin-putout": "^23.0.0",
46
45
  "lerna": "^6.0.1",
47
46
  "madrun": "^10.0.0",
48
47
  "mock-require": "^3.0.3",
@@ -52,6 +51,9 @@
52
51
  "supertape": "^10.0.0",
53
52
  "try-catch": "^3.0.0"
54
53
  },
54
+ "peerDependencies": {
55
+ "eslint": ">=8"
56
+ },
55
57
  "license": "MIT",
56
58
  "engines": {
57
59
  "node": ">=18"