@hyperupcall/eslint-config 0.11.0 → 1.2.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/README.md +1 -1
- package/output/index.cjs +65 -0
- package/output/index.d.ts +2 -0
- package/output/index.mjs +63 -0
- package/package.json +63 -28
- package/dist/eslintrc.cjs +0 -47
- package/dist/eslintrc.mjs +0 -45
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@ pnpm i -D \
|
|
|
10
10
|
eslint-plugin-import eslint-plugin-markdown eslint-plugin-promise \
|
|
11
11
|
eslint-plugin-n eslint-plugin-unicorn eslint-plugin-security \
|
|
12
12
|
@eslint-community/eslint-plugin-eslint-comments eslint-plugin-regexp \
|
|
13
|
-
eslint-plugin-perfectionist eslint-plugin-no-unsanitized eslint-mdx
|
|
13
|
+
eslint-plugin-perfectionist eslint-plugin-no-unsanitized eslint-plugin-mdx
|
|
14
14
|
```
|
|
15
15
|
|
|
16
16
|
## Usage
|
package/output/index.cjs
ADDED
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
require('globals');
|
|
4
|
+
var langJs = require('@eslint/js');
|
|
5
|
+
var langMarkdown = require('@eslint/markdown');
|
|
6
|
+
var langMdx = require('eslint-plugin-mdx');
|
|
7
|
+
var pluginPromise = require('eslint-plugin-promise');
|
|
8
|
+
var pluginNode = require('eslint-plugin-n');
|
|
9
|
+
var pluginSecurity = require('eslint-plugin-security');
|
|
10
|
+
var pluginComments = require('@eslint-community/eslint-plugin-eslint-comments/configs');
|
|
11
|
+
var pluginUnicorn = require('eslint-plugin-unicorn');
|
|
12
|
+
var pluginRegexp = require('eslint-plugin-regexp');
|
|
13
|
+
var pluginNoUnsanitized = require('eslint-plugin-no-unsanitized');
|
|
14
|
+
var pluginPerfectionist = require('eslint-plugin-perfectionist');
|
|
15
|
+
var configPrettier = require('eslint-config-prettier');
|
|
16
|
+
|
|
17
|
+
// TODO: import-x
|
|
18
|
+
|
|
19
|
+
// const config = {
|
|
20
|
+
// "extends": [
|
|
21
|
+
// "plugin:import/recommended",
|
|
22
|
+
// "plugin:mdx/recommended",
|
|
23
|
+
// ],
|
|
24
|
+
// "env": {
|
|
25
|
+
// "shared-node-browser": true,
|
|
26
|
+
// "es2022": true
|
|
27
|
+
// },
|
|
28
|
+
// "parserOptions": {
|
|
29
|
+
// "ecmaVersion": 2022,
|
|
30
|
+
// "sourceType": "module"
|
|
31
|
+
// },
|
|
32
|
+
// "overrides": [
|
|
33
|
+
// {
|
|
34
|
+
// "files": ["*.cjs"],
|
|
35
|
+
// "env": {
|
|
36
|
+
// "commonjs": true
|
|
37
|
+
// },
|
|
38
|
+
// "parserOptions": {
|
|
39
|
+
// "sourceType": "script"
|
|
40
|
+
// }
|
|
41
|
+
// }
|
|
42
|
+
// ]
|
|
43
|
+
// }
|
|
44
|
+
|
|
45
|
+
const config = [
|
|
46
|
+
langJs.configs.recommended,
|
|
47
|
+
...langMarkdown.configs.recommended,
|
|
48
|
+
{
|
|
49
|
+
...langMdx.flat,
|
|
50
|
+
processor: langMdx.createRemarkProcessor({
|
|
51
|
+
lintCodeBlocks: true,
|
|
52
|
+
}),
|
|
53
|
+
},
|
|
54
|
+
pluginPromise.configs['flat/recommended'],
|
|
55
|
+
pluginNode.configs["flat/recommended-script"],
|
|
56
|
+
pluginSecurity.configs.recommended,
|
|
57
|
+
pluginComments.recomended,
|
|
58
|
+
pluginUnicorn.configs['flat/recommended'],
|
|
59
|
+
pluginRegexp.configs["flat/recommended"],
|
|
60
|
+
pluginNoUnsanitized.configs.recommended,
|
|
61
|
+
pluginPerfectionist.configs['recommended-natural'],
|
|
62
|
+
configPrettier
|
|
63
|
+
];
|
|
64
|
+
|
|
65
|
+
module.exports = config;
|
package/output/index.mjs
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import 'globals';
|
|
2
|
+
import langJs from '@eslint/js';
|
|
3
|
+
import langMarkdown from '@eslint/markdown';
|
|
4
|
+
import langMdx from 'eslint-plugin-mdx';
|
|
5
|
+
import pluginPromise from 'eslint-plugin-promise';
|
|
6
|
+
import pluginNode from 'eslint-plugin-n';
|
|
7
|
+
import pluginSecurity from 'eslint-plugin-security';
|
|
8
|
+
import pluginComments from '@eslint-community/eslint-plugin-eslint-comments/configs';
|
|
9
|
+
import pluginUnicorn from 'eslint-plugin-unicorn';
|
|
10
|
+
import pluginRegexp from 'eslint-plugin-regexp';
|
|
11
|
+
import pluginNoUnsanitized from 'eslint-plugin-no-unsanitized';
|
|
12
|
+
import pluginPerfectionist from 'eslint-plugin-perfectionist';
|
|
13
|
+
import configPrettier from 'eslint-config-prettier';
|
|
14
|
+
|
|
15
|
+
// TODO: import-x
|
|
16
|
+
|
|
17
|
+
// const config = {
|
|
18
|
+
// "extends": [
|
|
19
|
+
// "plugin:import/recommended",
|
|
20
|
+
// "plugin:mdx/recommended",
|
|
21
|
+
// ],
|
|
22
|
+
// "env": {
|
|
23
|
+
// "shared-node-browser": true,
|
|
24
|
+
// "es2022": true
|
|
25
|
+
// },
|
|
26
|
+
// "parserOptions": {
|
|
27
|
+
// "ecmaVersion": 2022,
|
|
28
|
+
// "sourceType": "module"
|
|
29
|
+
// },
|
|
30
|
+
// "overrides": [
|
|
31
|
+
// {
|
|
32
|
+
// "files": ["*.cjs"],
|
|
33
|
+
// "env": {
|
|
34
|
+
// "commonjs": true
|
|
35
|
+
// },
|
|
36
|
+
// "parserOptions": {
|
|
37
|
+
// "sourceType": "script"
|
|
38
|
+
// }
|
|
39
|
+
// }
|
|
40
|
+
// ]
|
|
41
|
+
// }
|
|
42
|
+
|
|
43
|
+
const config = [
|
|
44
|
+
langJs.configs.recommended,
|
|
45
|
+
...langMarkdown.configs.recommended,
|
|
46
|
+
{
|
|
47
|
+
...langMdx.flat,
|
|
48
|
+
processor: langMdx.createRemarkProcessor({
|
|
49
|
+
lintCodeBlocks: true,
|
|
50
|
+
}),
|
|
51
|
+
},
|
|
52
|
+
pluginPromise.configs['flat/recommended'],
|
|
53
|
+
pluginNode.configs["flat/recommended-script"],
|
|
54
|
+
pluginSecurity.configs.recommended,
|
|
55
|
+
pluginComments.recomended,
|
|
56
|
+
pluginUnicorn.configs['flat/recommended'],
|
|
57
|
+
pluginRegexp.configs["flat/recommended"],
|
|
58
|
+
pluginNoUnsanitized.configs.recommended,
|
|
59
|
+
pluginPerfectionist.configs['recommended-natural'],
|
|
60
|
+
configPrettier
|
|
61
|
+
];
|
|
62
|
+
|
|
63
|
+
export { config as default };
|
package/package.json
CHANGED
|
@@ -1,43 +1,78 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hyperupcall/eslint-config",
|
|
3
|
-
"version": "
|
|
4
|
-
"
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
"version": "1.2.0",
|
|
4
|
+
"description": "Edwin's ESLint configuration.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "https://github.com/fox-land/eslint-config-hyperupcall.git"
|
|
9
|
+
},
|
|
10
|
+
"bugs": {
|
|
11
|
+
"url": "https://github.com/fox-land/eslint-config-hyperupcall/issues"
|
|
12
|
+
},
|
|
13
|
+
"author": "Edwin Kofler <edwin@kofler.dev> (https://edwinkofler.com)",
|
|
8
14
|
"license": "MPL-2.0",
|
|
9
15
|
"exports": {
|
|
10
|
-
"
|
|
11
|
-
|
|
16
|
+
".": {
|
|
17
|
+
"import": "./output/index.mjs",
|
|
18
|
+
"require": "./output/index.cjs"
|
|
19
|
+
}
|
|
12
20
|
},
|
|
21
|
+
"files": [
|
|
22
|
+
"output"
|
|
23
|
+
],
|
|
13
24
|
"peerDependencies": {
|
|
14
|
-
"eslint": ">=
|
|
15
|
-
"eslint
|
|
25
|
+
"@eslint-community/eslint-plugin-eslint-comments": ">=4.0.0",
|
|
26
|
+
"@eslint/js": "^9.0.0",
|
|
27
|
+
"eslint": "^9.0.0",
|
|
28
|
+
"eslint-config-prettier": ">=9.1.0",
|
|
29
|
+
"eslint-plugin-import": ">=2.29.0",
|
|
30
|
+
"eslint-plugin-markdown": ">=5.0.0",
|
|
31
|
+
"eslint-plugin-mdx": ">=3.0.0",
|
|
32
|
+
"eslint-plugin-n": ">=17.0.0",
|
|
33
|
+
"eslint-plugin-no-unsanitized": ">=4.0.0",
|
|
34
|
+
"eslint-plugin-perfectionist": ">=3.0.0",
|
|
35
|
+
"eslint-plugin-promise": ">=7.0.0",
|
|
36
|
+
"eslint-plugin-regexp": ">=2.0.0",
|
|
37
|
+
"eslint-plugin-security": ">=3.0.0",
|
|
38
|
+
"eslint-plugin-unicorn": ">=55.0.0"
|
|
16
39
|
},
|
|
17
40
|
"devDependencies": {
|
|
41
|
+
"@eslint-community/eslint-plugin-eslint-comments": "^4.4.0",
|
|
42
|
+
"@eslint/js": "^9.9.0",
|
|
43
|
+
"@hyperupcall/eslint-config": "^0.11.0",
|
|
18
44
|
"@hyperupcall/markdownlint-config": "^0.3.2",
|
|
19
|
-
"@hyperupcall/prettier-config": "^0.
|
|
20
|
-
"
|
|
21
|
-
"eslint": "^
|
|
22
|
-
"eslint-config-prettier": "^
|
|
23
|
-
"eslint-plugin-import": "^2.29.
|
|
24
|
-
"eslint-plugin-markdown": "^
|
|
25
|
-
"
|
|
26
|
-
"
|
|
27
|
-
"
|
|
45
|
+
"@hyperupcall/prettier-config": "^0.8.0",
|
|
46
|
+
"@rollup/plugin-node-resolve": "^15.3.0",
|
|
47
|
+
"eslint": "^9.9.0",
|
|
48
|
+
"eslint-config-prettier": "^9.1.0",
|
|
49
|
+
"eslint-plugin-import": "^2.29.1",
|
|
50
|
+
"eslint-plugin-markdown": "^5.1.0",
|
|
51
|
+
"eslint-plugin-mdx": "^3.1.5",
|
|
52
|
+
"eslint-plugin-n": "^17.10.2",
|
|
53
|
+
"eslint-plugin-no-unsanitized": "^4.0.2",
|
|
54
|
+
"eslint-plugin-perfectionist": "^3.2.0",
|
|
55
|
+
"eslint-plugin-promise": "^7.1.0",
|
|
56
|
+
"eslint-plugin-regexp": "^2.6.0",
|
|
57
|
+
"eslint-plugin-security": "^3.0.1",
|
|
58
|
+
"eslint-plugin-unicorn": "^55.0.0",
|
|
59
|
+
"markdownlint": "^0.34.0",
|
|
60
|
+
"prettier": "^3.3.3",
|
|
61
|
+
"prettier-plugin-pkg": "^0.18.1",
|
|
62
|
+
"rollup": "^4.24.4",
|
|
63
|
+
"typescript": "^5.6.3"
|
|
28
64
|
},
|
|
29
|
-
"
|
|
30
|
-
|
|
31
|
-
"bugs": {
|
|
32
|
-
"url": "https://github.com/fox-land/eslint-config-hyperupcall/issues"
|
|
65
|
+
"dependencies": {
|
|
66
|
+
"globals": "^15.9.0"
|
|
33
67
|
},
|
|
34
|
-
"
|
|
35
|
-
"
|
|
36
|
-
"url": "https://github.com/fox-land/eslint-config-hyperupcall.git"
|
|
68
|
+
"markdownlint-cli2": {
|
|
69
|
+
"extends": "./node_modules/@hyperupcall/markdownlint-config/.markdownlint.json"
|
|
37
70
|
},
|
|
71
|
+
"private": false,
|
|
72
|
+
"prettier": "@hyperupcall/scripts-nodejs/config-prettier.js",
|
|
38
73
|
"scripts": {
|
|
39
|
-
"build": "
|
|
40
|
-
"
|
|
41
|
-
"
|
|
74
|
+
"build": "rm -rf ./output && rollup --config ./rollup.config.js && tsc --project ./tsconfig.json",
|
|
75
|
+
"format": "prettier --check .",
|
|
76
|
+
"lint": "eslint ."
|
|
42
77
|
}
|
|
43
78
|
}
|
package/dist/eslintrc.cjs
DELETED
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2
|
-
|
|
3
|
-
function getDefaultExportFromCjs (x) {
|
|
4
|
-
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
var src = {
|
|
8
|
-
extends: [
|
|
9
|
-
'eslint:recommended',
|
|
10
|
-
'plugin:import/recommended',
|
|
11
|
-
'plugin:markdown/recommended',
|
|
12
|
-
'plugin:promise/recommended',
|
|
13
|
-
'plugin:n/recommended',
|
|
14
|
-
'plugin:unicorn/recommended',
|
|
15
|
-
// 'plugin:security/recommended-legacy',
|
|
16
|
-
'plugin:@eslint-community/eslint-comments/recommended',
|
|
17
|
-
'plugin:regexp/recommended',
|
|
18
|
-
'eslint-config-prettier',
|
|
19
|
-
'plugin:perfectionist/recommended-natural',
|
|
20
|
-
'plugin:no-unsanitized/DOM',
|
|
21
|
-
'plugin:mdx/recommended'
|
|
22
|
-
],
|
|
23
|
-
env: {
|
|
24
|
-
'shared-node-browser': true,
|
|
25
|
-
es2022: true
|
|
26
|
-
},
|
|
27
|
-
parserOptions: {
|
|
28
|
-
ecmaVersion: 2022,
|
|
29
|
-
sourceType: 'module'
|
|
30
|
-
},
|
|
31
|
-
overrides: [
|
|
32
|
-
{
|
|
33
|
-
files: [
|
|
34
|
-
'*.cjs'
|
|
35
|
-
],
|
|
36
|
-
env: {
|
|
37
|
-
commonjs: true
|
|
38
|
-
},
|
|
39
|
-
parserOptions: {
|
|
40
|
-
sourceType: 'script'
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
]
|
|
44
|
-
};
|
|
45
|
-
var index = /*@__PURE__*/ getDefaultExportFromCjs(src);
|
|
46
|
-
|
|
47
|
-
exports.default = index;
|
package/dist/eslintrc.mjs
DELETED
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
function getDefaultExportFromCjs (x) {
|
|
2
|
-
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
var src = {
|
|
6
|
-
extends: [
|
|
7
|
-
'eslint:recommended',
|
|
8
|
-
'plugin:import/recommended',
|
|
9
|
-
'plugin:markdown/recommended',
|
|
10
|
-
'plugin:promise/recommended',
|
|
11
|
-
'plugin:n/recommended',
|
|
12
|
-
'plugin:unicorn/recommended',
|
|
13
|
-
// 'plugin:security/recommended-legacy',
|
|
14
|
-
'plugin:@eslint-community/eslint-comments/recommended',
|
|
15
|
-
'plugin:regexp/recommended',
|
|
16
|
-
'eslint-config-prettier',
|
|
17
|
-
'plugin:perfectionist/recommended-natural',
|
|
18
|
-
'plugin:no-unsanitized/DOM',
|
|
19
|
-
'plugin:mdx/recommended'
|
|
20
|
-
],
|
|
21
|
-
env: {
|
|
22
|
-
'shared-node-browser': true,
|
|
23
|
-
es2022: true
|
|
24
|
-
},
|
|
25
|
-
parserOptions: {
|
|
26
|
-
ecmaVersion: 2022,
|
|
27
|
-
sourceType: 'module'
|
|
28
|
-
},
|
|
29
|
-
overrides: [
|
|
30
|
-
{
|
|
31
|
-
files: [
|
|
32
|
-
'*.cjs'
|
|
33
|
-
],
|
|
34
|
-
env: {
|
|
35
|
-
commonjs: true
|
|
36
|
-
},
|
|
37
|
-
parserOptions: {
|
|
38
|
-
sourceType: 'script'
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
]
|
|
42
|
-
};
|
|
43
|
-
var index = /*@__PURE__*/ getDefaultExportFromCjs(src);
|
|
44
|
-
|
|
45
|
-
export { index as default };
|