@nice-move/eslint-config-base 0.11.33 → 0.11.35
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 +0 -17
- package/lib/base.cjs +45 -21
- package/lib/bundler.cjs +1 -4
- package/lib/import.cjs +1 -0
- package/lib/markdown.cjs +0 -5
- package/lib/mini.cjs +28 -23
- package/lib/node.cjs +29 -73
- package/lib/test.cjs +0 -1
- package/lib/typescript.cjs +1 -5
- package/lib/utils.cjs +25 -13
- package/package.json +6 -9
- package/lib/electron.cjs +0 -31
- package/lib/playwright.cjs +0 -19
package/index.cjs
CHANGED
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const {
|
|
4
|
-
configHas,
|
|
5
|
-
matches: { sourceAndPackages },
|
|
6
|
-
} = require('./lib/utils.cjs');
|
|
7
3
|
const { readJson, getPkg } = require('settingz');
|
|
8
4
|
|
|
9
5
|
function ignoreList() {
|
|
@@ -31,8 +27,6 @@ module.exports = {
|
|
|
31
27
|
require.resolve('./lib/promise.cjs'),
|
|
32
28
|
require.resolve('./lib/import.cjs'),
|
|
33
29
|
require.resolve('./lib/base.cjs'),
|
|
34
|
-
require.resolve('./lib/electron.cjs'),
|
|
35
|
-
require.resolve('./lib/playwright.cjs'),
|
|
36
30
|
require.resolve('./lib/node.cjs'),
|
|
37
31
|
require.resolve('./lib/bundler.cjs'),
|
|
38
32
|
require.resolve('./lib/typescript.cjs'),
|
|
@@ -43,17 +37,6 @@ module.exports = {
|
|
|
43
37
|
'plugin:regexp/recommended',
|
|
44
38
|
'prettier',
|
|
45
39
|
],
|
|
46
|
-
...configHas(
|
|
47
|
-
({ globals }) => globals,
|
|
48
|
-
(globals) => ({
|
|
49
|
-
overrides: [
|
|
50
|
-
{
|
|
51
|
-
files: sourceAndPackages,
|
|
52
|
-
globals,
|
|
53
|
-
},
|
|
54
|
-
],
|
|
55
|
-
}),
|
|
56
|
-
),
|
|
57
40
|
ignorePatterns: [
|
|
58
41
|
'!.*',
|
|
59
42
|
'.cache/',
|
package/lib/base.cjs
CHANGED
|
@@ -1,40 +1,63 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
const { getGlobals } = require('../lib/utils.cjs');
|
|
4
|
+
|
|
3
5
|
module.exports = {
|
|
4
6
|
env: {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
es2024: true,
|
|
8
|
-
es2023: true,
|
|
9
|
-
es2022: true,
|
|
10
|
-
es2021: true,
|
|
11
|
-
es2020: true,
|
|
12
|
-
es2019: true,
|
|
13
|
-
es2018: true,
|
|
14
|
-
es2017: true,
|
|
15
|
-
es2016: true,
|
|
7
|
+
es2025: true,
|
|
8
|
+
browser: false,
|
|
16
9
|
node: false,
|
|
10
|
+
commonjs: false,
|
|
11
|
+
},
|
|
12
|
+
globals: getGlobals({ es2025: true }),
|
|
13
|
+
parserOptions: {
|
|
14
|
+
ecmaFeatures: {
|
|
15
|
+
globalReturn: false,
|
|
16
|
+
impliedStrict: true,
|
|
17
|
+
jsx: false,
|
|
18
|
+
},
|
|
19
|
+
ecmaVersion: 'latest',
|
|
20
|
+
sourceType: 'module',
|
|
17
21
|
},
|
|
18
22
|
extends: ['plugin:@eslint-community/eslint-comments/recommended'],
|
|
19
23
|
overrides: [
|
|
20
24
|
{
|
|
21
|
-
files: ['
|
|
25
|
+
files: ['**/*.ts', '**/*.tsx', '**/*.js', '**/*.jsx'],
|
|
26
|
+
env: {
|
|
27
|
+
es2025: true,
|
|
28
|
+
browser: true,
|
|
29
|
+
node: false,
|
|
30
|
+
commonjs: false,
|
|
31
|
+
},
|
|
32
|
+
globals: getGlobals({ es2025: true, browser: true }),
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
files: ['**/*.jsx', '**/*.tsx'],
|
|
22
36
|
parserOptions: {
|
|
23
37
|
ecmaFeatures: {
|
|
24
38
|
jsx: true,
|
|
25
39
|
},
|
|
26
40
|
},
|
|
27
41
|
},
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
42
|
+
{
|
|
43
|
+
files: ['**/*.cjs'],
|
|
44
|
+
parserOptions: {
|
|
45
|
+
sourceType: 'script',
|
|
46
|
+
ecmaFeatures: {
|
|
47
|
+
impliedStrict: false,
|
|
48
|
+
},
|
|
49
|
+
},
|
|
34
50
|
},
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
51
|
+
{
|
|
52
|
+
files: ['**/*.cts'],
|
|
53
|
+
parserOptions: {
|
|
54
|
+
sourceType: 'module',
|
|
55
|
+
ecmaFeatures: {
|
|
56
|
+
impliedStrict: true,
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
],
|
|
38
61
|
rules: {
|
|
39
62
|
'lines-around-directive': 0,
|
|
40
63
|
'array-callback-return': [
|
|
@@ -111,6 +134,7 @@ module.exports = {
|
|
|
111
134
|
{
|
|
112
135
|
argsIgnorePattern: '^_+$',
|
|
113
136
|
ignoreRestSiblings: true,
|
|
137
|
+
reportUsedIgnorePattern: true,
|
|
114
138
|
varsIgnorePattern: '^_+$',
|
|
115
139
|
},
|
|
116
140
|
],
|
package/lib/bundler.cjs
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const {
|
|
4
|
-
matches: { source },
|
|
5
|
-
} = require('./utils.cjs');
|
|
6
3
|
const { isReachable } = require('settingz');
|
|
7
4
|
|
|
8
5
|
function webpack() {
|
|
@@ -10,7 +7,7 @@ function webpack() {
|
|
|
10
7
|
isReachable('best-shot/package.json')
|
|
11
8
|
? [
|
|
12
9
|
{
|
|
13
|
-
files:
|
|
10
|
+
files: ['src/**'],
|
|
14
11
|
excludedFiles: ['*.html', '*.htm'],
|
|
15
12
|
globals: {
|
|
16
13
|
__webpack_public_path__: true,
|
package/lib/import.cjs
CHANGED
package/lib/markdown.cjs
CHANGED
package/lib/mini.cjs
CHANGED
|
@@ -4,6 +4,7 @@ const { relative } = require('node:path');
|
|
|
4
4
|
const { reaching } = require('settingz');
|
|
5
5
|
|
|
6
6
|
const cwd = process.cwd();
|
|
7
|
+
const { getGlobals } = require('../lib/utils.cjs');
|
|
7
8
|
|
|
8
9
|
function relativeToCWD(path) {
|
|
9
10
|
return relative(cwd, path);
|
|
@@ -46,10 +47,8 @@ function generate({
|
|
|
46
47
|
{
|
|
47
48
|
files: matcher(paths, '**'),
|
|
48
49
|
excludedFiles,
|
|
49
|
-
env: {
|
|
50
|
-
browser: false,
|
|
51
|
-
},
|
|
52
50
|
globals: {
|
|
51
|
+
...getGlobals({ es2025: true }),
|
|
53
52
|
...globals,
|
|
54
53
|
wx: 'readonly',
|
|
55
54
|
getApp: 'readonly',
|
|
@@ -84,10 +83,8 @@ function generate({
|
|
|
84
83
|
cloudMatcher
|
|
85
84
|
? {
|
|
86
85
|
files: [cloudMatcher],
|
|
87
|
-
env: {
|
|
88
|
-
browser: false,
|
|
89
|
-
},
|
|
90
86
|
globals: {
|
|
87
|
+
...getGlobals(),
|
|
91
88
|
...globals,
|
|
92
89
|
require: 'readonly',
|
|
93
90
|
exports: 'readonly',
|
|
@@ -100,28 +97,36 @@ function generate({
|
|
|
100
97
|
: undefined,
|
|
101
98
|
{
|
|
102
99
|
files: excludedFiles,
|
|
103
|
-
env: {
|
|
104
|
-
browser: false,
|
|
105
|
-
es2023: false,
|
|
106
|
-
es2022: false,
|
|
107
|
-
es2021: false,
|
|
108
|
-
es2020: false,
|
|
109
|
-
es2019: false,
|
|
110
|
-
es2018: false,
|
|
111
|
-
es2017: false,
|
|
112
|
-
es2016: false,
|
|
113
|
-
es6: false,
|
|
114
|
-
node: false,
|
|
115
|
-
},
|
|
116
100
|
parserOptions: {
|
|
117
101
|
ecmaVersion: 5,
|
|
118
102
|
sourceType: 'script',
|
|
103
|
+
ecmaFeatures: {
|
|
104
|
+
globalReturn: false,
|
|
105
|
+
impliedStrict: false,
|
|
106
|
+
jsx: false,
|
|
107
|
+
},
|
|
119
108
|
},
|
|
120
109
|
globals: {
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
110
|
+
...getGlobals(),
|
|
111
|
+
Date: false,
|
|
112
|
+
decodeURI: false,
|
|
113
|
+
decodeURIComponent: false,
|
|
114
|
+
encodeURI: false,
|
|
115
|
+
encodeURIComponent: false,
|
|
116
|
+
getDate: false,
|
|
117
|
+
getRegExp: false,
|
|
118
|
+
Infinity: false,
|
|
119
|
+
isFinite: false,
|
|
120
|
+
isNaN: false,
|
|
121
|
+
JSON: false,
|
|
122
|
+
Math: false,
|
|
123
|
+
module: false,
|
|
124
|
+
NaN: false,
|
|
125
|
+
Number: false,
|
|
126
|
+
parseFloat: false,
|
|
127
|
+
parseInt: false,
|
|
128
|
+
require: false,
|
|
129
|
+
undefined: false,
|
|
125
130
|
},
|
|
126
131
|
rules: {
|
|
127
132
|
'import/no-commonjs': 0,
|
package/lib/node.cjs
CHANGED
|
@@ -1,12 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const {
|
|
3
|
+
const { getGlobals } = require('./utils.cjs');
|
|
4
4
|
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
({ commonjs: globs = [] }) => globs,
|
|
8
|
-
(globs) => globs,
|
|
9
|
-
) || [];
|
|
5
|
+
const esmConfig = require('eslint-plugin-n/lib/configs/recommended-module');
|
|
6
|
+
const cjsConfig = require('eslint-plugin-n/lib/configs/recommended-script');
|
|
10
7
|
|
|
11
8
|
module.exports = {
|
|
12
9
|
plugins: ['n'],
|
|
@@ -16,33 +13,33 @@ module.exports = {
|
|
|
16
13
|
'n/no-path-concat': 'error',
|
|
17
14
|
},
|
|
18
15
|
overrides: [
|
|
16
|
+
{
|
|
17
|
+
files: ['**/*.{js,jsx,ts,tsx,mjs,mts,cts,vue}'],
|
|
18
|
+
rules: esmConfig.eslintrc.rules,
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
files: ['**/*.{cjs,qs,wxs}'],
|
|
22
|
+
rules: cjsConfig.eslintrc.rules,
|
|
23
|
+
},
|
|
19
24
|
{
|
|
20
25
|
files: '**/*',
|
|
21
|
-
excludedFiles: ['*.cjs', '*.cts'
|
|
26
|
+
excludedFiles: ['*.cjs', '*.cts'],
|
|
22
27
|
rules: {
|
|
23
28
|
'import/no-commonjs': 'error',
|
|
24
29
|
},
|
|
25
30
|
},
|
|
26
31
|
{
|
|
27
|
-
files: '
|
|
32
|
+
files: '**/*.{m,c}{t,j}s',
|
|
28
33
|
env: {
|
|
29
|
-
browser: false,
|
|
30
34
|
node: true,
|
|
31
|
-
commonjs: true,
|
|
32
35
|
},
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
'import/no-nodejs-modules': 'off',
|
|
38
|
-
'unicorn/prefer-module': 'off',
|
|
36
|
+
parserOptions: {
|
|
37
|
+
ecmaFeatures: {
|
|
38
|
+
globalReturn: true,
|
|
39
|
+
},
|
|
39
40
|
},
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
files: '*.{m,c}{t,j}s',
|
|
43
|
-
excludedFiles: '*.nb.*',
|
|
44
|
-
env: {
|
|
45
|
-
node: true,
|
|
41
|
+
globals: {
|
|
42
|
+
...getGlobals({ es2025: true, node: true }),
|
|
46
43
|
},
|
|
47
44
|
rules: {
|
|
48
45
|
'n/no-deprecated-api': 'error',
|
|
@@ -60,61 +57,14 @@ module.exports = {
|
|
|
60
57
|
},
|
|
61
58
|
},
|
|
62
59
|
{
|
|
63
|
-
files: '
|
|
64
|
-
excludedFiles: [
|
|
65
|
-
'*.{m,c}ts',
|
|
66
|
-
'*.cjs',
|
|
67
|
-
'*.md',
|
|
68
|
-
'*.nb.*',
|
|
69
|
-
'*.ts',
|
|
70
|
-
'**/*.md/*',
|
|
71
|
-
...commonjs,
|
|
72
|
-
],
|
|
60
|
+
files: '**/*.*',
|
|
61
|
+
excludedFiles: ['*.cjs', '*.md', '**/*.md/*'],
|
|
73
62
|
rules: {
|
|
74
63
|
'n/file-extension-in-import': 'error',
|
|
75
64
|
},
|
|
76
65
|
},
|
|
77
66
|
{
|
|
78
|
-
files: ['
|
|
79
|
-
parser: '@babel/eslint-parser',
|
|
80
|
-
parserOptions: {
|
|
81
|
-
requireConfigFile: false,
|
|
82
|
-
babelOptions: {
|
|
83
|
-
babelrc: false,
|
|
84
|
-
configFile: false,
|
|
85
|
-
plugins: [require.resolve('@babel/plugin-syntax-import-attributes')],
|
|
86
|
-
},
|
|
87
|
-
},
|
|
88
|
-
},
|
|
89
|
-
{
|
|
90
|
-
// for node.js
|
|
91
|
-
files: ['*.mjs', '*.mts'],
|
|
92
|
-
excludedFiles: '*.nb.*',
|
|
93
|
-
env: {
|
|
94
|
-
browser: false,
|
|
95
|
-
commonjs: false,
|
|
96
|
-
},
|
|
97
|
-
globals: {
|
|
98
|
-
__dirname: 'off',
|
|
99
|
-
__filename: 'off',
|
|
100
|
-
exports: 'off',
|
|
101
|
-
module: 'off',
|
|
102
|
-
require: 'off',
|
|
103
|
-
},
|
|
104
|
-
},
|
|
105
|
-
{
|
|
106
|
-
files: ['*.cjs', ...commonjs],
|
|
107
|
-
excludedFiles: '*.nb.*',
|
|
108
|
-
env: {
|
|
109
|
-
browser: false,
|
|
110
|
-
commonjs: true,
|
|
111
|
-
},
|
|
112
|
-
parserOptions: {
|
|
113
|
-
ecmaFeatures: {
|
|
114
|
-
impliedStrict: false,
|
|
115
|
-
},
|
|
116
|
-
sourceType: 'script',
|
|
117
|
-
},
|
|
67
|
+
files: ['**/*.cjs'],
|
|
118
68
|
rules: {
|
|
119
69
|
strict: ['error', 'global'],
|
|
120
70
|
'n/no-exports-assign': 'error',
|
|
@@ -122,10 +72,16 @@ module.exports = {
|
|
|
122
72
|
},
|
|
123
73
|
},
|
|
124
74
|
{
|
|
125
|
-
files: ['
|
|
75
|
+
files: ['**/*.cjs', '**/*.cts'],
|
|
126
76
|
rules: {
|
|
127
77
|
'unicorn/prefer-module': 'off',
|
|
128
78
|
},
|
|
129
79
|
},
|
|
80
|
+
{
|
|
81
|
+
files: ['**/*.mjs', '**/*.mts'],
|
|
82
|
+
env: {
|
|
83
|
+
commonjs: false,
|
|
84
|
+
},
|
|
85
|
+
},
|
|
130
86
|
],
|
|
131
87
|
};
|
package/lib/test.cjs
CHANGED
package/lib/typescript.cjs
CHANGED
|
@@ -17,7 +17,6 @@ module.exports = {
|
|
|
17
17
|
'@typescript-eslint/no-extra-non-null-assertion': 'error',
|
|
18
18
|
'@typescript-eslint/no-extraneous-class': 'error',
|
|
19
19
|
'@typescript-eslint/no-invalid-void-type': 'error',
|
|
20
|
-
'@typescript-eslint/no-loss-of-precision': 'error',
|
|
21
20
|
'@typescript-eslint/no-misused-new': 'error',
|
|
22
21
|
'@typescript-eslint/no-namespace': 'error',
|
|
23
22
|
'@typescript-eslint/no-non-null-asserted-nullish-coalescing': 'error',
|
|
@@ -27,21 +26,18 @@ module.exports = {
|
|
|
27
26
|
'@typescript-eslint/no-unnecessary-type-constraint': 'error',
|
|
28
27
|
'@typescript-eslint/no-unsafe-declaration-merging': 'error',
|
|
29
28
|
'@typescript-eslint/no-useless-constructor': 'error',
|
|
30
|
-
'@typescript-eslint/no-var-requires': 'error',
|
|
31
29
|
'@typescript-eslint/prefer-as-const': 'error',
|
|
32
30
|
'@typescript-eslint/prefer-literal-enum-member': 'error',
|
|
33
|
-
'@typescript-eslint/prefer-ts-expect-error': 'error',
|
|
34
31
|
'@typescript-eslint/triple-slash-reference': 'error',
|
|
35
32
|
'@typescript-eslint/unified-signatures': 'error',
|
|
36
|
-
|
|
37
33
|
'@typescript-eslint/no-explicit-any': 'warn',
|
|
38
|
-
'@typescript-eslint/ban-ts-comment': 0,
|
|
39
34
|
'@typescript-eslint/no-empty-function': 0,
|
|
40
35
|
'@typescript-eslint/no-unused-vars': [
|
|
41
36
|
'warn',
|
|
42
37
|
{
|
|
43
38
|
argsIgnorePattern: '^_+$',
|
|
44
39
|
ignoreRestSiblings: true,
|
|
40
|
+
reportUsedIgnorePattern: true,
|
|
45
41
|
varsIgnorePattern: '^_+$',
|
|
46
42
|
},
|
|
47
43
|
],
|
package/lib/utils.cjs
CHANGED
|
@@ -1,20 +1,23 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
const { getPkg } = require('settingz');
|
|
4
|
+
const globals = require('globals');
|
|
4
5
|
|
|
5
6
|
// eslint-disable-next-line consistent-return
|
|
6
|
-
function pkgHas(checker, getResult) {
|
|
7
|
+
exports.pkgHas = function pkgHas(checker, getResult) {
|
|
7
8
|
const pkg = getPkg();
|
|
8
9
|
|
|
9
10
|
const io = checker(pkg);
|
|
10
11
|
|
|
11
12
|
if (io) {
|
|
12
|
-
return getResult(io, pkg);
|
|
13
|
+
return getResult(io, pkg) || [];
|
|
13
14
|
}
|
|
14
|
-
|
|
15
|
+
|
|
16
|
+
return [];
|
|
17
|
+
};
|
|
15
18
|
|
|
16
19
|
// eslint-disable-next-line consistent-return
|
|
17
|
-
function configHas(checker, getResult) {
|
|
20
|
+
exports.configHas = function configHas(checker, getResult) {
|
|
18
21
|
const pkg = getPkg('nice-move');
|
|
19
22
|
|
|
20
23
|
const io = checker(pkg);
|
|
@@ -22,13 +25,22 @@ function configHas(checker, getResult) {
|
|
|
22
25
|
if (io) {
|
|
23
26
|
return getResult(io, pkg);
|
|
24
27
|
}
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
exports.getGlobals = function getGlobals(env = {}) {
|
|
31
|
+
return Object.fromEntries([
|
|
32
|
+
...Object.keys({
|
|
33
|
+
...globals.browser,
|
|
34
|
+
...globals.node,
|
|
35
|
+
...globals.es2025,
|
|
36
|
+
}).map((key) => [key, 'off']),
|
|
37
|
+
...Object.entries(env).flatMap(([key, on]) =>
|
|
38
|
+
on
|
|
39
|
+
? Object.entries(globals[key] || {}).map(([k, v]) => [
|
|
40
|
+
k,
|
|
41
|
+
v ? 'writable' : 'readonly',
|
|
42
|
+
])
|
|
43
|
+
: Object.keys(globals[key] || {}).map((k) => [k, 'off']),
|
|
44
|
+
),
|
|
45
|
+
]);
|
|
34
46
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nice-move/eslint-config-base",
|
|
3
|
-
"version": "0.11.
|
|
3
|
+
"version": "0.11.35",
|
|
4
4
|
"description": "A `eslint` config for best practice",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": {
|
|
@@ -34,18 +34,15 @@
|
|
|
34
34
|
},
|
|
35
35
|
"main": "index.cjs",
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@babel/core": "^7.26.0",
|
|
38
|
-
"@babel/eslint-parser": "^7.25.9",
|
|
39
|
-
"@babel/plugin-syntax-import-attributes": "^7.26.0",
|
|
40
37
|
"@eslint-community/eslint-plugin-eslint-comments": "^4.4.1",
|
|
41
|
-
"@nice-move/eslint-plugin-html": "0.
|
|
42
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
43
|
-
"@typescript-eslint/parser": "^8.
|
|
38
|
+
"@nice-move/eslint-plugin-html": "^0.1.1",
|
|
39
|
+
"@typescript-eslint/eslint-plugin": "^8.19.0",
|
|
40
|
+
"@typescript-eslint/parser": "^8.19.0",
|
|
44
41
|
"eslint-config-airbnb-base": "^15.0.0",
|
|
45
42
|
"eslint-config-prettier": "^9.1.0",
|
|
46
43
|
"eslint-plugin-import": "^2.31.0",
|
|
47
44
|
"eslint-plugin-markdown": "^5.1.0",
|
|
48
|
-
"eslint-plugin-n": "^17.15.
|
|
45
|
+
"eslint-plugin-n": "^17.15.1",
|
|
49
46
|
"eslint-plugin-promise": "^7.2.1",
|
|
50
47
|
"eslint-plugin-regexp": "^2.7.0",
|
|
51
48
|
"eslint-plugin-unicorn": "^56.0.1",
|
|
@@ -57,7 +54,7 @@
|
|
|
57
54
|
"eslint": "^8.57.1"
|
|
58
55
|
},
|
|
59
56
|
"engines": {
|
|
60
|
-
"node": "^
|
|
57
|
+
"node": "^22.11.0"
|
|
61
58
|
},
|
|
62
59
|
"publishConfig": {
|
|
63
60
|
"access": "public",
|
package/lib/electron.cjs
DELETED
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const {
|
|
4
|
-
pkgHas,
|
|
5
|
-
matches: { source },
|
|
6
|
-
} = require('./utils.cjs');
|
|
7
|
-
|
|
8
|
-
module.exports =
|
|
9
|
-
pkgHas(
|
|
10
|
-
({ devDependencies: { electron } = {} }) => electron,
|
|
11
|
-
() => ({
|
|
12
|
-
overrides: [
|
|
13
|
-
{
|
|
14
|
-
files: source,
|
|
15
|
-
settings: {
|
|
16
|
-
'import/core-modules': ['electron'],
|
|
17
|
-
},
|
|
18
|
-
globals: {
|
|
19
|
-
Buffer: 'readonly',
|
|
20
|
-
clearImmediate: 'readonly',
|
|
21
|
-
global: 'readonly',
|
|
22
|
-
process: 'readonly',
|
|
23
|
-
setImmediate: 'readonly',
|
|
24
|
-
},
|
|
25
|
-
rules: {
|
|
26
|
-
'import/no-nodejs-modules': 'off',
|
|
27
|
-
},
|
|
28
|
-
},
|
|
29
|
-
],
|
|
30
|
-
}),
|
|
31
|
-
) || {};
|
package/lib/playwright.cjs
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const { pkgHas } = require('./utils.cjs');
|
|
4
|
-
|
|
5
|
-
module.exports =
|
|
6
|
-
pkgHas(
|
|
7
|
-
({ peerDependencies: { '@playwright/test': playwright } = {} }) =>
|
|
8
|
-
playwright,
|
|
9
|
-
() => ({
|
|
10
|
-
overrides: [
|
|
11
|
-
{
|
|
12
|
-
files: 'test/**',
|
|
13
|
-
settings: {
|
|
14
|
-
'import/core-modules': ['@playwright/test'],
|
|
15
|
-
},
|
|
16
|
-
},
|
|
17
|
-
],
|
|
18
|
-
}),
|
|
19
|
-
) || {};
|