@alexlit/lint-kit 108.1.0 → 110.0.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/package.json +1 -1
- package/packages/config-commitlint/package.json +3 -3
- package/packages/config-eslint/dictionaries/index.js +5 -4
- package/packages/config-eslint/package.json +4 -4
- package/packages/config-prettier/README.md +21 -9
- package/packages/config-prettier/index.js +96 -37
- package/packages/config-prettier/package.json +3 -2
- package/packages/config-prettier/plugins/jsdoc.js +1 -1
- package/packages/config-prettier/plugins/packagejson.js +3 -0
- package/packages/config-prettier/plugins/php.js +3 -0
- package/packages/config-prettier/plugins/pug.js +2 -1
- package/packages/config-prettier/plugins/ruby.js +3 -0
- package/packages/config-prettier/plugins/sh.js +3 -0
- package/packages/config-prettier/plugins/solidity.js +3 -0
- package/packages/config-prettier/plugins/sort-json.js +2 -1
- package/packages/config-prettier/plugins/sql.js +3 -0
- package/packages/config-prettier/plugins/svelte.js +2 -1
- package/packages/config-prettier/plugins/tailwindcss.js +2 -1
- package/packages/config-prettier/plugins/xml.js +2 -1
- package/packages/config-stylelint/README.md +38 -16
- package/packages/config-stylelint/index.js +103 -23
- package/packages/config-stylelint/package.json +1 -1
- package/packages/config-stylelint/plugins/a11y.js +0 -1
- package/packages/config-stylelint/plugins/at-rule-no-children.js +0 -1
- package/packages/config-stylelint/plugins/color-format.js +0 -1
- package/packages/config-stylelint/plugins/declaration-block-no-ignored-properties.js +0 -1
- package/packages/config-stylelint/plugins/{optional/gamut.js → gamut.js} +0 -1
- package/packages/config-stylelint/plugins/high-performance-animation.js +0 -1
- package/packages/config-stylelint/plugins/{optional/logical-css.js → logical-css.js} +0 -1
- package/packages/config-stylelint/plugins/{optional/no-indistinguishable-colors.js → no-indistinguishable-colors.js} +0 -1
- package/packages/config-stylelint/plugins/no-nested-media.js +0 -1
- package/packages/config-stylelint/plugins/no-unresolved-module.js +0 -1
- package/packages/config-stylelint/plugins/no-unsupported-browser-features.js +0 -1
- package/packages/config-stylelint/plugins/order.js +0 -1
- package/packages/config-stylelint/plugins/prettier.js +0 -1
- package/packages/config-stylelint/plugins/scss.js +0 -1
- package/packages/config-stylelint/plugins/selector-no-empty.js +0 -1
- package/packages/config-stylelint/plugins/use-nesting.js +0 -1
- package/packages/config-stylelint/plugins/vue.js +0 -2
- package/prettier.config.js +7 -4
- package/stylelint.config.js +5 -13
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alexlit/config-commitlint",
|
|
3
|
-
"version": "11.
|
|
3
|
+
"version": "11.1.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Commitlint config",
|
|
6
6
|
"keywords": [
|
|
@@ -32,8 +32,8 @@
|
|
|
32
32
|
"up": "../../scripts/up.sh"
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@commitlint/cli": "^19.0
|
|
36
|
-
"@commitlint/config-conventional": "^19.0
|
|
35
|
+
"@commitlint/cli": "^19.1.0",
|
|
36
|
+
"@commitlint/config-conventional": "^19.1.0",
|
|
37
37
|
"conventional-changelog-cli": "^4.1.0"
|
|
38
38
|
}
|
|
39
39
|
}
|
|
@@ -23,11 +23,7 @@ const specialized = [
|
|
|
23
23
|
module.exports = [
|
|
24
24
|
...programming,
|
|
25
25
|
...specialized,
|
|
26
|
-
'jsonc',
|
|
27
26
|
'aave',
|
|
28
|
-
'changelogen',
|
|
29
|
-
'maxerr',
|
|
30
|
-
'tailwindcss',
|
|
31
27
|
'airbnb',
|
|
32
28
|
'aland',
|
|
33
29
|
'alexey',
|
|
@@ -85,6 +81,7 @@ module.exports = [
|
|
|
85
81
|
'centos',
|
|
86
82
|
'chaina',
|
|
87
83
|
'changelly',
|
|
84
|
+
'changelogen',
|
|
88
85
|
'chartjs',
|
|
89
86
|
'checkboxes',
|
|
90
87
|
'chokidar',
|
|
@@ -209,6 +206,7 @@ module.exports = [
|
|
|
209
206
|
'jsdoc',
|
|
210
207
|
'jsdoc',
|
|
211
208
|
'jsnext',
|
|
209
|
+
'jsonc',
|
|
212
210
|
'junit',
|
|
213
211
|
'kakao',
|
|
214
212
|
'kanban',
|
|
@@ -242,6 +240,7 @@ module.exports = [
|
|
|
242
240
|
'mastercard',
|
|
243
241
|
'materialdesignicons',
|
|
244
242
|
'mattermost',
|
|
243
|
+
'maxerr',
|
|
245
244
|
'mercurio',
|
|
246
245
|
'mercuryo',
|
|
247
246
|
'metafile',
|
|
@@ -294,6 +293,7 @@ module.exports = [
|
|
|
294
293
|
'osascript',
|
|
295
294
|
'outdent',
|
|
296
295
|
'outdir',
|
|
296
|
+
'packagejson',
|
|
297
297
|
'parens',
|
|
298
298
|
'pathname',
|
|
299
299
|
'patreon',
|
|
@@ -378,6 +378,7 @@ module.exports = [
|
|
|
378
378
|
'svgstore',
|
|
379
379
|
'systemize',
|
|
380
380
|
'tagless',
|
|
381
|
+
'tailwindcss',
|
|
381
382
|
'tanstack',
|
|
382
383
|
'taobao',
|
|
383
384
|
'taurus',
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alexlit/config-eslint",
|
|
3
|
-
"version": "76.
|
|
3
|
+
"version": "76.7.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Eslint config",
|
|
6
6
|
"keywords": [
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@intlify/eslint-plugin-vue-i18n": "^2.0.0",
|
|
37
|
-
"@tanstack/eslint-plugin-query": "^5.
|
|
37
|
+
"@tanstack/eslint-plugin-query": "^5.27.3",
|
|
38
38
|
"@typescript-eslint/eslint-plugin": "^6.21.0",
|
|
39
39
|
"@typescript-eslint/parser": "^6.21.0",
|
|
40
40
|
"eslint": "^8.57.0",
|
|
@@ -77,8 +77,8 @@
|
|
|
77
77
|
"eslint-plugin-typescript-sort-keys": "^3.2.0",
|
|
78
78
|
"eslint-plugin-unicorn": "^51.0.1",
|
|
79
79
|
"eslint-plugin-unused-imports": "^3.1.0",
|
|
80
|
-
"eslint-plugin-vitest": "^0.3.
|
|
81
|
-
"eslint-plugin-vue": "^9.
|
|
80
|
+
"eslint-plugin-vitest": "^0.3.26",
|
|
81
|
+
"eslint-plugin-vue": "^9.23.0",
|
|
82
82
|
"eslint-plugin-vuejs-accessibility": "^2.2.1",
|
|
83
83
|
"eslint-plugin-wc": "^2.0.4",
|
|
84
84
|
"eslint-plugin-write-good-comments": "^0.2.0",
|
|
@@ -8,14 +8,26 @@ npm i @alexlit/config-prettier -D
|
|
|
8
8
|
|
|
9
9
|
## Connection
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
import config from '@alexlit/config-prettier';
|
|
11
|
+
- Default
|
|
12
|
+
([see plugins enabled by default](https://github.com/alex-lit/lint-kit/blob/master/packages/config-prettier/index.js#L5))
|
|
14
13
|
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
```js
|
|
15
|
+
// prettier.config.js
|
|
16
|
+
import { createConfig } from '@alexlit/config-prettier';
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
18
|
+
export default createConfig();
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
- Custom
|
|
22
|
+
|
|
23
|
+
```js
|
|
24
|
+
// prettier.config.js
|
|
25
|
+
import { createConfig } from '@alexlit/config-prettier';
|
|
26
|
+
|
|
27
|
+
export default createConfig({
|
|
28
|
+
php: true,
|
|
29
|
+
ruby: true,
|
|
30
|
+
sql: false,
|
|
31
|
+
tailwindcss: false,
|
|
32
|
+
});
|
|
33
|
+
```
|
|
@@ -1,38 +1,97 @@
|
|
|
1
|
-
/* eslint-disable
|
|
2
|
-
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
]
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
1
|
+
/* eslint-disable no-loops/no-loops, no-restricted-syntax, no-await-in-loop */
|
|
2
|
+
|
|
3
|
+
import { omit } from 'radash';
|
|
4
|
+
|
|
5
|
+
const PLUGINS = {
|
|
6
|
+
/** @see [prettier-plugin-jsdoc](https://github.com/hosseinmd/prettier-plugin-jsdoc) */
|
|
7
|
+
jsdoc: true,
|
|
8
|
+
|
|
9
|
+
/** @see [prettier-plugin-packagejson](https://github.com/matzkoh/prettier-plugin-packagejson) */
|
|
10
|
+
packagejson: true,
|
|
11
|
+
|
|
12
|
+
/** @see [plugin-php](https://github.com/prettier/plugin-php) */
|
|
13
|
+
php: false,
|
|
14
|
+
|
|
15
|
+
/** @see [plugin-pug](https://github.com/prettier/plugin-pug) */
|
|
16
|
+
pug: true,
|
|
17
|
+
|
|
18
|
+
/** @see [plugin-ruby](https://github.com/prettier/plugin-ruby) */
|
|
19
|
+
ruby: false,
|
|
20
|
+
|
|
21
|
+
/** @see [prettier-plugin-sh](https://github.com/astorije/prettier-plugin-sh) */
|
|
22
|
+
sh: true,
|
|
23
|
+
|
|
24
|
+
/** @see [prettier-plugin-solidity](https://github.com/prettier-solidity/prettier-plugin-solidity) */
|
|
25
|
+
solidity: true,
|
|
26
|
+
|
|
27
|
+
/** @see [prettier-plugin-sort-json](https://github.com/Gudahtt/prettier-plugin-sort-json) */
|
|
28
|
+
'sort-json': true,
|
|
29
|
+
|
|
30
|
+
/** @see [prettier-plugin-sql](https://github.com/un-ts/prettier/tree/master/packages/sql) */
|
|
31
|
+
sql: false,
|
|
32
|
+
|
|
33
|
+
/** @see [prettier-plugin-svelte](https://github.com/sveltejs/prettier-plugin-svelte) */
|
|
34
|
+
svelte: false,
|
|
35
|
+
|
|
36
|
+
/** @see [prettier-plugin-tailwindcss](https://github.com/tailwindlabs/prettier-plugin-tailwindcss) */
|
|
37
|
+
tailwindcss: false,
|
|
38
|
+
|
|
39
|
+
/** @see [plugin-xml](https://github.com/prettier/plugin-xml) */
|
|
40
|
+
xml: true,
|
|
41
|
+
};
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* Create plugins config list
|
|
45
|
+
*
|
|
46
|
+
* @param {PLUGINS} plugins Enabled/disabled plugins list
|
|
47
|
+
*
|
|
48
|
+
* @returns {import('prettier').Config} Prettier configuration
|
|
49
|
+
*/
|
|
50
|
+
const createPluginsConfig = async (plugins = {}) => {
|
|
51
|
+
let pluginsConfig = { plugins: [] };
|
|
52
|
+
|
|
53
|
+
const pluginEntries = Object.entries({ ...PLUGINS, ...plugins });
|
|
54
|
+
|
|
55
|
+
for (const [name, isActive] of pluginEntries) {
|
|
56
|
+
if (isActive) {
|
|
57
|
+
const { default: config } = await import(
|
|
58
|
+
`@alexlit/config-prettier/plugins/${name}.js`
|
|
59
|
+
);
|
|
60
|
+
|
|
61
|
+
if (config.plugins?.length > 0) {
|
|
62
|
+
pluginsConfig.plugins.push(...config.plugins);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
pluginsConfig = { ...pluginsConfig, ...omit(config, ['plugins']) };
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
return pluginsConfig;
|
|
70
|
+
};
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* Create prettier config
|
|
74
|
+
*
|
|
75
|
+
* @param {PLUGINS} plugins
|
|
76
|
+
* @param {import('prettier').Config} options Prettier options
|
|
77
|
+
*
|
|
78
|
+
* @returns {import('prettier').Config} Prettier configuration
|
|
79
|
+
*/
|
|
80
|
+
export const createConfig = async (plugins = {}, options = {}) => {
|
|
81
|
+
const pluginsConfig = await createPluginsConfig(plugins);
|
|
82
|
+
|
|
83
|
+
return {
|
|
84
|
+
endOfLine: 'lf',
|
|
85
|
+
|
|
86
|
+
plugins: [...pluginsConfig.plugins, ...(options.plugins ?? [])],
|
|
87
|
+
|
|
88
|
+
proseWrap: 'always',
|
|
89
|
+
singleQuote: true,
|
|
90
|
+
tabWidth: 2,
|
|
91
|
+
trailingComma: 'all',
|
|
92
|
+
vueIndentScriptAndStyle: true,
|
|
93
|
+
|
|
94
|
+
...omit(pluginsConfig, ['plugins']),
|
|
95
|
+
...omit(options, ['plugins']),
|
|
96
|
+
};
|
|
38
97
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alexlit/config-prettier",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "17.0.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "prettier config",
|
|
6
6
|
"keywords": [
|
|
@@ -45,7 +45,8 @@
|
|
|
45
45
|
"prettier-plugin-sort-json": "^3.1.0",
|
|
46
46
|
"prettier-plugin-sql": "^0.18.0",
|
|
47
47
|
"prettier-plugin-svelte": "^3.2.2",
|
|
48
|
-
"prettier-plugin-tailwindcss": "^0.5.12"
|
|
48
|
+
"prettier-plugin-tailwindcss": "^0.5.12",
|
|
49
|
+
"radash": "^12.1.0"
|
|
49
50
|
},
|
|
50
51
|
"engines": {
|
|
51
52
|
"node": ">=18.12.0"
|
|
@@ -8,22 +8,44 @@ npm i @alexlit/config-stylelint -D
|
|
|
8
8
|
|
|
9
9
|
## Connection
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
};
|
|
26
|
-
|
|
11
|
+
- Default
|
|
12
|
+
([see plugins enabled by default](https://github.com/alex-lit/lint-kit/blob/master/packages/config-stylelint/index.js#L62))
|
|
13
|
+
|
|
14
|
+
```js
|
|
15
|
+
// stylelint.config.js
|
|
16
|
+
import { createConfig } from '@alexlit/config-stylelint';
|
|
17
|
+
|
|
18
|
+
export default createConfig();
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
- Custom
|
|
22
|
+
|
|
23
|
+
```js
|
|
24
|
+
// stylelint.config.js
|
|
25
|
+
import { createConfig } from '@alexlit/config-stylelint';
|
|
26
|
+
|
|
27
|
+
export default createConfig(
|
|
28
|
+
{
|
|
29
|
+
// disable some default plugins
|
|
30
|
+
'no-nested-media': false,
|
|
31
|
+
|
|
32
|
+
// enable some optional plugins
|
|
33
|
+
gamut: true,
|
|
34
|
+
'logical-css': true,
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
// add custom rules
|
|
38
|
+
rules: {
|
|
39
|
+
'custom-property-empty-line-before': [
|
|
40
|
+
'always',
|
|
41
|
+
{
|
|
42
|
+
except: ['after-comment', 'after-custom-property', 'first-nested'],
|
|
43
|
+
},
|
|
44
|
+
],
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
);
|
|
48
|
+
```
|
|
27
49
|
|
|
28
50
|
## Development
|
|
29
51
|
|
|
@@ -1,28 +1,100 @@
|
|
|
1
|
-
/* eslint-disable sonarjs/no-duplicate-string, unicorn/no-null */
|
|
2
|
-
|
|
1
|
+
/* eslint-disable no-console, import/extensions, sonarjs/no-duplicate-string, unicorn/no-null */
|
|
2
|
+
|
|
3
|
+
const ADDITIONAL_PLUGINS = {
|
|
4
|
+
/** @see [stylelint-a11y](https://github.com/double-great/stylelint-a11y) */
|
|
5
|
+
a11y: true,
|
|
6
|
+
|
|
7
|
+
/** @see [stylelint-at-rule-no-children](https://github.com/adityavm/stylelint-at-rule-no-children) */
|
|
8
|
+
'at-rule-no-children': true,
|
|
9
|
+
|
|
10
|
+
/** @see [stylelint-color-format](https://github.com/filipekiss/stylelint-color-format) */
|
|
11
|
+
'color-format': true,
|
|
12
|
+
|
|
13
|
+
/** @see [stylelint-declaration-block-no-ignored-properties](https://github.com/kristerkari/stylelint-declaration-block-no-ignored-properties) */
|
|
14
|
+
'declaration-block-no-ignored-properties': true,
|
|
15
|
+
|
|
16
|
+
/** @see [stylelint-high-performance-animation](https://github.com/kristerkari/stylelint-high-performance-animation) */
|
|
17
|
+
'high-performance-animation': true,
|
|
18
|
+
|
|
19
|
+
/** @see [stylelint-no-nested-media](https://github.com/dkrnl/stylelint-no-nested-media) */
|
|
20
|
+
'no-nested-media': true,
|
|
21
|
+
|
|
22
|
+
/** @see [stylelint-no-unresolved-module](https://github.com/niksy/stylelint-no-unresolved-module) */
|
|
23
|
+
'no-unresolved-module': true,
|
|
24
|
+
|
|
25
|
+
/** @see [stylelint-no-unsupported-browser-features](https://github.com/ismay/stylelint-no-unsupported-browser-features) */
|
|
26
|
+
'no-unsupported-browser-features': true,
|
|
27
|
+
|
|
28
|
+
/** @see [stylelint-order](https://github.com/hudochenkov/stylelint-order) */
|
|
29
|
+
order: true,
|
|
30
|
+
|
|
31
|
+
/** @see [stylelint-scss](https://github.com/kristerkari/stylelint-scss) */
|
|
32
|
+
scss: true,
|
|
33
|
+
|
|
34
|
+
/** @see [stylelint-selector-no-empty](https://github.com/ssivanatarajan/stylelint-selector-no-empty) */
|
|
35
|
+
'selector-no-empty': true,
|
|
36
|
+
|
|
37
|
+
/** @see [stylelint-use-nesting](https://github.com/csstools/stylelint-use-nesting) */
|
|
38
|
+
'use-nesting': true,
|
|
39
|
+
|
|
40
|
+
/** @see [stylelint-config-recommended-vue](https://github.com/ota-meshi/stylelint-config-recommended-vue) */
|
|
41
|
+
vue: true,
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
const OPTIONAL_PLUGINS = {
|
|
45
|
+
/** @see [stylelint-gamut](https://github.com/fpetrakov/stylelint-gamut) */
|
|
46
|
+
gamut: false,
|
|
47
|
+
|
|
48
|
+
/** @see [stylelint-plugin-logical-css](https://github.com/yuschick/stylelint-plugin-logical-css) */
|
|
49
|
+
'logical-css': false,
|
|
50
|
+
|
|
51
|
+
/** @see [stylelint-no-indistinguishable-colors](https://github.com/ierhyna/stylelint-no-indistinguishable-colors) */
|
|
52
|
+
'no-indistinguishable-colors': false,
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
const PRETTIER_PLUGINS = {
|
|
56
|
+
/** @see [stylelint-prettier](https://github.com/prettier/stylelint-prettier) */
|
|
57
|
+
prettier: true,
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
const PLUGINS = {
|
|
61
|
+
...ADDITIONAL_PLUGINS,
|
|
62
|
+
...OPTIONAL_PLUGINS,
|
|
63
|
+
...PRETTIER_PLUGINS,
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* Create "extends" field
|
|
68
|
+
*
|
|
69
|
+
* @param {PLUGINS} plugins Enabled/disabled plugins list
|
|
70
|
+
*/
|
|
71
|
+
const createPluginsList = (plugins = {}) => {
|
|
72
|
+
const pluginsList = [];
|
|
73
|
+
|
|
74
|
+
Object.entries({ ...PLUGINS, ...plugins })?.forEach(([name, isActive]) => {
|
|
75
|
+
if (isActive) {
|
|
76
|
+
pluginsList.push(`@alexlit/config-stylelint/plugins/${name}`);
|
|
77
|
+
}
|
|
78
|
+
});
|
|
79
|
+
|
|
80
|
+
return pluginsList;
|
|
81
|
+
};
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* Create stylelint config
|
|
85
|
+
*
|
|
86
|
+
* @param {PLUGINS} plugins Enabled/disabled plugins list
|
|
87
|
+
* @param {import('stylelint').Config} options Stylelint config
|
|
88
|
+
*/
|
|
89
|
+
const createConfig = (plugins = {}, options = {}) => ({
|
|
90
|
+
...options,
|
|
91
|
+
|
|
3
92
|
extends: [
|
|
4
93
|
'stylelint-config-standard',
|
|
5
94
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
'./plugins/declaration-block-no-ignored-properties',
|
|
10
|
-
'./plugins/high-performance-animation',
|
|
11
|
-
'./plugins/no-nested-media',
|
|
12
|
-
'./plugins/no-unresolved-module',
|
|
13
|
-
'./plugins/no-unsupported-browser-features',
|
|
14
|
-
'./plugins/order',
|
|
15
|
-
'./plugins/scss',
|
|
16
|
-
'./plugins/selector-no-empty',
|
|
17
|
-
// './plugins/use-nesting',
|
|
18
|
-
'./plugins/vue',
|
|
19
|
-
|
|
20
|
-
'./plugins/prettier',
|
|
21
|
-
|
|
22
|
-
// optional
|
|
23
|
-
// './plugins/optional/gamut',
|
|
24
|
-
// './plugins/optional/no-indistinguishable-colors',
|
|
25
|
-
// './plugins/optional/logical-css',
|
|
95
|
+
...createPluginsList(plugins),
|
|
96
|
+
|
|
97
|
+
...(options.extends ?? []),
|
|
26
98
|
],
|
|
27
99
|
|
|
28
100
|
ignoreFiles: [
|
|
@@ -32,8 +104,12 @@ export default {
|
|
|
32
104
|
'docs/**',
|
|
33
105
|
'node_modules/**',
|
|
34
106
|
'storybook-*/**',
|
|
107
|
+
|
|
108
|
+
...(options.ignoreFiles ?? []),
|
|
35
109
|
],
|
|
36
110
|
|
|
111
|
+
plugins: options.plugins ?? [],
|
|
112
|
+
|
|
37
113
|
rules: {
|
|
38
114
|
'alpha-value-notation': 'number',
|
|
39
115
|
'annotation-no-unknown': [true, { ignoreAnnotations: ['default'] }],
|
|
@@ -146,5 +222,9 @@ export default {
|
|
|
146
222
|
],
|
|
147
223
|
|
|
148
224
|
'value-no-vendor-prefix': true,
|
|
225
|
+
|
|
226
|
+
...options.rules,
|
|
149
227
|
},
|
|
150
|
-
};
|
|
228
|
+
});
|
|
229
|
+
|
|
230
|
+
export { createConfig };
|
package/prettier.config.js
CHANGED
package/stylelint.config.js
CHANGED
|
@@ -1,14 +1,6 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { createConfig } from '@alexlit/config-stylelint';
|
|
2
2
|
|
|
3
|
-
export default {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
/* optional */
|
|
8
|
-
'@alexlit/config-stylelint/plugins/optional/gamut',
|
|
9
|
-
// '@alexlit/config-stylelint/plugins/optional/no-indistinguishable-colors',
|
|
10
|
-
'@alexlit/config-stylelint/plugins/optional/logical-css',
|
|
11
|
-
],
|
|
12
|
-
|
|
13
|
-
ignoreFiles: [...config.ignoreFiles],
|
|
14
|
-
};
|
|
3
|
+
export default createConfig({
|
|
4
|
+
gamut: true,
|
|
5
|
+
'logical-css': true,
|
|
6
|
+
});
|