@nice-move/eslint-config-base 0.5.77 → 0.6.1

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.cjs CHANGED
@@ -4,7 +4,6 @@ const {
4
4
  configHas,
5
5
  matches: { sourceAndPackages },
6
6
  } = require('./lib/utils.cjs');
7
-
8
7
  const { readJson, getPkg } = require('settingz');
9
8
 
10
9
  function ignoreList() {
@@ -17,6 +16,7 @@ function BestShot() {
17
16
  const { git = [], eslint = git } = readJson(
18
17
  '@best-shot/cli/config/ignore.json',
19
18
  );
19
+
20
20
  return eslint;
21
21
  }
22
22
 
package/lib/bundler.cjs CHANGED
@@ -3,19 +3,7 @@
3
3
  const {
4
4
  matches: { source, sourceAndPackages },
5
5
  } = require('./utils.cjs');
6
-
7
- const { reaching, isReachable } = require('settingz');
8
-
9
- function BestShot() {
10
- return isReachable('@best-shot/preset-env/package.json')
11
- ? [
12
- {
13
- files: sourceAndPackages,
14
- ...reaching('@best-shot/preset-env/eslint.cjs'),
15
- },
16
- ]
17
- : [];
18
- }
6
+ const { isReachable } = require('settingz');
19
7
 
20
8
  function webpack() {
21
9
  return isReachable('webpack/package.json')
@@ -54,5 +42,5 @@ function webpack() {
54
42
  }
55
43
 
56
44
  module.exports = {
57
- overrides: [...webpack(), ...BestShot()],
45
+ overrides: webpack(),
58
46
  };
package/lib/import.cjs CHANGED
@@ -1,7 +1,6 @@
1
1
  'use strict';
2
2
 
3
3
  const { join } = require('path');
4
-
5
4
  const { pkgHas, configHas } = require('./utils.cjs');
6
5
 
7
6
  const Vscode = pkgHas(
@@ -29,7 +28,7 @@ module.exports = {
29
28
  '**/.*rc.{m,c,}{t,j}s',
30
29
  '**/*.config.{m,c,}{t,j}s',
31
30
  '**/config.{m,c,}{t,j}s',
32
- '.best-shot/**',
31
+ '**/.best-shot/**',
33
32
  ],
34
33
  },
35
34
  ],
@@ -7,6 +7,7 @@ module.exports = {
7
7
  parse(code, options) {
8
8
  // eslint-disable-next-line no-param-reassign
9
9
  options.ecmaFeatures.jsx = true;
10
+
10
11
  return espree.parse(code, options);
11
12
  },
12
13
  };
package/lib/mini.cjs CHANGED
@@ -1,7 +1,6 @@
1
1
  'use strict';
2
2
 
3
3
  const { relative } = require('path');
4
-
5
4
  const { reaching } = require('settingz');
6
5
 
7
6
  const cwd = process.cwd();
package/lib/node.cjs CHANGED
@@ -7,7 +7,6 @@ module.exports = {
7
7
  'n/no-process-env': 'error',
8
8
  'n/no-path-concat': 'error',
9
9
  },
10
- extends: ['plugin:n/recommended'],
11
10
  overrides: [
12
11
  {
13
12
  files: '*.{m,c}js',
@@ -33,7 +32,7 @@ module.exports = {
33
32
  },
34
33
  {
35
34
  files: '*.*',
36
- excludedFiles: ['**/*.md/*', '*.cjs', '*.md'],
35
+ excludedFiles: ['**/*.md/*', '*.cjs', '*.ts', '*.cts', '*.mts', '*.md'],
37
36
  rules: {
38
37
  'n/file-extension-in-import': 'error',
39
38
  },
@@ -16,7 +16,7 @@ function filterObject(object, filter) {
16
16
  module.exports = {
17
17
  overrides: [
18
18
  {
19
- files: ['*.ts', '*.tsx'],
19
+ files: ['*.ts', '*.tsx', '*.mts', '*.cts'],
20
20
  parser: '@typescript-eslint/parser',
21
21
  plugins: ['@typescript-eslint'],
22
22
  // parserOptions: {
@@ -30,6 +30,7 @@ module.exports = {
30
30
  rules: {
31
31
  ...filterObject(base, (_key, value) => value !== 'off' && value !== 0),
32
32
  ...rules,
33
+ '@typescript-eslint/ban-ts-comment': 0,
33
34
  '@typescript-eslint/no-unused-vars': [
34
35
  'warn',
35
36
  {
package/lib/utils.cjs CHANGED
@@ -7,6 +7,7 @@ function pkgHas(checker, getResult) {
7
7
  const pkg = getPkg();
8
8
 
9
9
  const io = checker(pkg);
10
+
10
11
  if (io) {
11
12
  return getResult(io, pkg);
12
13
  }
@@ -17,6 +18,7 @@ function configHas(checker, getResult) {
17
18
  const pkg = getPkg('nice-move');
18
19
 
19
20
  const io = checker(pkg);
21
+
20
22
  if (io) {
21
23
  return getResult(io, pkg);
22
24
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nice-move/eslint-config-base",
3
- "version": "0.5.77",
3
+ "version": "0.6.1",
4
4
  "description": "A `eslint` config for best practice",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -34,23 +34,23 @@
34
34
  },
35
35
  "main": "index.cjs",
36
36
  "dependencies": {
37
- "@typescript-eslint/eslint-plugin": "^5.8.0",
38
- "@typescript-eslint/parser": "^5.8.0",
37
+ "@typescript-eslint/eslint-plugin": "^5.10.1",
38
+ "@typescript-eslint/parser": "^5.10.1",
39
39
  "eslint-config-airbnb-base": "^15.0.0",
40
40
  "eslint-config-prettier": "^8.3.0",
41
41
  "eslint-plugin-eslint-comments": "^3.2.0",
42
42
  "eslint-plugin-html": "^6.2.0",
43
- "eslint-plugin-import": "^2.25.3",
43
+ "eslint-plugin-import": "^2.25.4",
44
44
  "eslint-plugin-markdown": "^2.2.1",
45
45
  "eslint-plugin-n": "^14.0.0",
46
46
  "eslint-plugin-promise": "^6.0.0",
47
47
  "eslint-plugin-sonarjs": "^0.11.0",
48
- "eslint-plugin-unicorn": "^39.0.0",
49
- "espree": "9.2.0",
50
- "settingz": "^0.1.3"
48
+ "eslint-plugin-unicorn": "^40.1.0",
49
+ "espree": "^9.3.0",
50
+ "settingz": "^0.1.5"
51
51
  },
52
52
  "peerDependencies": {
53
- "eslint": "^7.32.0"
53
+ "eslint": "^8.6.0"
54
54
  },
55
55
  "engines": {
56
56
  "node": "^12.22.0 || ^14.17.0 || >=16.13.0"