@massimo-cassandro/stylelint-config 2.1.2 → 2.2.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.js +32 -41
- package/package.json +6 -5
package/index.js
CHANGED
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
/** @type {import('stylelint').Config} */
|
|
2
|
+
|
|
3
|
+
const tailwindAtRules = ['tailwind', 'apply', 'layer', 'variants', 'responsive', 'screen', 'config'],
|
|
4
|
+
postCSSRules = ['define-mixin', 'mixin'];
|
|
5
|
+
|
|
2
6
|
export default {
|
|
3
7
|
extends: [
|
|
4
8
|
'stylelint-config-standard',
|
|
@@ -20,67 +24,52 @@ export default {
|
|
|
20
24
|
rules: {
|
|
21
25
|
|
|
22
26
|
'alpha-value-notation': null,
|
|
27
|
+
'at-rule-empty-line-before': null,
|
|
23
28
|
'at-rule-no-vendor-prefix': true,
|
|
24
|
-
'at-rule-no-unknown': [
|
|
25
|
-
|
|
26
|
-
{
|
|
27
|
-
ignoreAtRules: [
|
|
28
|
-
// Tailwind CSS
|
|
29
|
-
'tailwind', 'apply', 'layer', 'variants', 'responsive', 'screen', 'config',
|
|
30
|
-
// PostCSS
|
|
31
|
-
'define-mixin', 'mixin',
|
|
32
|
-
// SCSS
|
|
33
|
-
'extend', 'include', 'if', 'else', 'function', 'at-root',
|
|
34
|
-
'use', 'forward', 'each', 'while', 'for', 'error', 'warn', 'debug', 'return'
|
|
35
|
-
]
|
|
36
|
-
}
|
|
37
|
-
],
|
|
29
|
+
'at-rule-no-unknown': [ true, { ignoreAtRules: [ ...tailwindAtRules, ...postCSSRules ] } ],
|
|
30
|
+
'color-function-notation': null,
|
|
38
31
|
'color-named': 'never',
|
|
39
32
|
'comment-empty-line-before': null,
|
|
33
|
+
'custom-property-empty-line-before': null,
|
|
34
|
+
'custom-property-pattern': null,
|
|
35
|
+
'declaration-block-no-redundant-longhand-properties': null,
|
|
36
|
+
'declaration-empty-line-before': null,
|
|
40
37
|
'declaration-no-important': true,
|
|
41
38
|
'font-family-name-quotes': 'always-where-recommended',
|
|
39
|
+
'font-weight-notation': ['numeric', { ignore: ['relative'] }],
|
|
42
40
|
'function-no-unknown': [true, { ignoreFunctions: ['theme'] }],
|
|
41
|
+
'function-url-no-scheme-relative': true,
|
|
43
42
|
'function-url-quotes': 'always',
|
|
43
|
+
'hue-degree-notation': null,
|
|
44
44
|
'import-notation': null,
|
|
45
45
|
'max-nesting-depth': [3, {
|
|
46
46
|
ignore: ['pseudo-classes', 'blockless-at-rules'],
|
|
47
47
|
ignoreAtRules: [/media/, /include/],
|
|
48
48
|
ignorePseudoClasses: ['before', 'after']
|
|
49
49
|
}],
|
|
50
|
-
'selector-attribute-quotes': 'always',
|
|
51
|
-
'selector-class-pattern': ['^[a-z][a-z0-9\\-]*[a-z0-9]$', { resolveNestedSelectors: true }],
|
|
52
|
-
'selector-max-type': [3, { ignore: ['child', 'compounded', 'descendant', 'next-sibling'] }],
|
|
53
|
-
'selector-max-universal': 1,
|
|
54
|
-
'selector-no-qualifying-type': true,
|
|
55
|
-
'selector-no-vendor-prefix': true,
|
|
56
|
-
'selector-pseudo-class-no-unknown': [true, { ignorePseudoClasses: ['global'] }],
|
|
57
|
-
'shorthand-property-no-redundant-values': true,
|
|
58
|
-
'value-keyword-case': ['lower', { ignoreKeywords: ['currentColor'] }],
|
|
59
|
-
'value-no-vendor-prefix': true,
|
|
60
|
-
|
|
61
|
-
// --- da stylelint-config-twbs-bootstrap ---
|
|
62
|
-
'at-rule-empty-line-before': null,
|
|
63
|
-
'color-function-notation': null,
|
|
64
|
-
'custom-property-empty-line-before': null,
|
|
65
|
-
'custom-property-pattern': null,
|
|
66
|
-
'declaration-block-no-redundant-longhand-properties': null,
|
|
67
|
-
'declaration-empty-line-before': null,
|
|
68
|
-
'font-weight-notation': ['numeric', { ignore: ['relative'] }],
|
|
69
|
-
'function-url-no-scheme-relative': true,
|
|
70
|
-
'hue-degree-notation': null,
|
|
71
50
|
'media-feature-range-notation': null,
|
|
72
51
|
'media-query-no-invalid': null,
|
|
73
52
|
'no-descending-specificity': null,
|
|
74
53
|
'number-max-precision': null,
|
|
75
54
|
'property-no-vendor-prefix': true,
|
|
76
55
|
'rule-empty-line-before': null,
|
|
56
|
+
'selector-attribute-quotes': 'always',
|
|
57
|
+
'selector-class-pattern': ['^[a-z][a-z0-9\\-]*[a-z0-9]$', { resolveNestedSelectors: true }],
|
|
77
58
|
'selector-max-attribute': 2,
|
|
78
59
|
'selector-max-class': 4,
|
|
79
60
|
'selector-max-combinators': 4,
|
|
80
61
|
'selector-max-compound-selectors': 4,
|
|
81
62
|
'selector-max-id': 0,
|
|
82
63
|
'selector-max-specificity': null,
|
|
64
|
+
'selector-max-type': [3, { ignore: ['child', 'compounded', 'descendant', 'next-sibling'] }],
|
|
65
|
+
'selector-max-universal': 1,
|
|
66
|
+
'selector-no-qualifying-type': null, // https://stylelint.io/user-guide/rules/selector-no-qualifying-type/
|
|
67
|
+
'selector-no-vendor-prefix': true,
|
|
83
68
|
'selector-not-notation': null,
|
|
69
|
+
'selector-pseudo-class-no-unknown': [true, { ignorePseudoClasses: ['global'] }],
|
|
70
|
+
'shorthand-property-no-redundant-values': true,
|
|
71
|
+
'value-keyword-case': ['lower', { ignoreKeywords: ['currentColor'] }],
|
|
72
|
+
'value-no-vendor-prefix': true,
|
|
84
73
|
|
|
85
74
|
// --- Stylistic ---
|
|
86
75
|
'@stylistic/at-rule-name-space-after': 'always',
|
|
@@ -124,22 +113,24 @@ export default {
|
|
|
124
113
|
'scss/at-if-closing-brace-newline-after': null,
|
|
125
114
|
'scss/at-if-closing-brace-space-after': null,
|
|
126
115
|
'scss/at-if-no-null': null,
|
|
127
|
-
'scss/at-import-no-partial-leading-underscore': null,
|
|
128
|
-
'scss/at-import-partial-extension': 'never',
|
|
129
116
|
'scss/at-mixin-argumentless-call-parentheses': 'always',
|
|
130
117
|
'scss/at-mixin-named-arguments': null,
|
|
131
118
|
'scss/at-mixin-parentheses-space-before': 'never',
|
|
132
119
|
'scss/at-mixin-pattern': null,
|
|
133
120
|
'scss/at-rule-conditional-no-parentheses': null,
|
|
121
|
+
'scss/load-no-partial-leading-underscore': true,
|
|
122
|
+
'scss/load-partial-extension': 'never',
|
|
123
|
+
|
|
124
|
+
'at-rule-no-unknown': null, // disabilita regola base per evitare conflitti
|
|
134
125
|
'scss/at-rule-no-unknown': [
|
|
135
126
|
true,
|
|
136
127
|
{
|
|
137
128
|
ignoreAtRules: [
|
|
138
|
-
|
|
139
|
-
|
|
129
|
+
...tailwindAtRules,
|
|
130
|
+
...postCSSRules,
|
|
140
131
|
// SCSS
|
|
141
|
-
'extend', 'include', 'if', 'else', '
|
|
142
|
-
'forward', 'each', 'while', 'for', 'error', 'warn', 'debug', 'return'
|
|
132
|
+
'extend', 'include', 'if', 'else', 'function', 'at-root',
|
|
133
|
+
'use', 'forward', 'each', 'while', 'for', 'error', 'warn', 'debug', 'return'
|
|
143
134
|
]
|
|
144
135
|
}
|
|
145
136
|
],
|
package/package.json
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@massimo-cassandro/stylelint-config",
|
|
3
|
-
"version": "2.1
|
|
3
|
+
"version": "2.2.1",
|
|
4
4
|
"description": "my stylelint config",
|
|
5
5
|
"author": "Massimo Cassandro",
|
|
6
6
|
"license": "MIT",
|
|
7
|
-
"main": "index.
|
|
7
|
+
"main": "index.js",
|
|
8
8
|
"type": "module",
|
|
9
9
|
"scripts": {
|
|
10
10
|
"UPD-version": "npx update-version #--config=./dev-utilities.config.mjs",
|
|
11
11
|
"upd@m": "npx upd@m",
|
|
12
|
+
"npm-upd": "npm update --save",
|
|
12
13
|
"npm-publish": "npm publish"
|
|
13
14
|
},
|
|
14
15
|
"publishConfig": {
|
|
@@ -30,7 +31,7 @@
|
|
|
30
31
|
],
|
|
31
32
|
"devDependencies": {
|
|
32
33
|
"@eslint/js": "^10.0.1",
|
|
33
|
-
"@massimo-cassandro/dev-updater": "^3.0.
|
|
34
|
+
"@massimo-cassandro/dev-updater": "^3.0.2",
|
|
34
35
|
"@massimo-cassandro/eslint-config": "^2.0.8",
|
|
35
36
|
"eslint": "^10.0.0",
|
|
36
37
|
"globals": "^17.3.0"
|
|
@@ -38,9 +39,9 @@
|
|
|
38
39
|
"dependencies": {
|
|
39
40
|
"@stylistic/stylelint-config": "^4.0.0",
|
|
40
41
|
"@stylistic/stylelint-plugin": "^5.0.1",
|
|
41
|
-
"stylelint": "^17.
|
|
42
|
+
"stylelint": "^17.3.0",
|
|
42
43
|
"stylelint-config-css-modules": "^4.6.0",
|
|
43
|
-
"stylelint-config-recess-order": "^7.6.
|
|
44
|
+
"stylelint-config-recess-order": "^7.6.1",
|
|
44
45
|
"stylelint-config-standard": "^40.0.0",
|
|
45
46
|
"stylelint-config-standard-scss": "^17.0.0",
|
|
46
47
|
"stylelint-scss": "^7.0.0"
|