@best-shot/preset-style 0.10.4 → 0.10.6
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/lib/apply-scss-less.mjs
CHANGED
|
@@ -11,6 +11,7 @@ export function applyScssLess(less) {
|
|
|
11
11
|
|
|
12
12
|
chain.module
|
|
13
13
|
.rule('sass')
|
|
14
|
+
.after('style')
|
|
14
15
|
.test(extToRegexp({ extname: ['scss', 'sass'] }))
|
|
15
16
|
.use('resolve-url-loader')
|
|
16
17
|
.loader('resolve-url-loader')
|
|
@@ -27,6 +28,7 @@ export function applyScssLess(less) {
|
|
|
27
28
|
|
|
28
29
|
chain.module
|
|
29
30
|
.rule('less')
|
|
31
|
+
.after('style')
|
|
30
32
|
.test(extToRegexp({ extname: ['less'] }))
|
|
31
33
|
.use('less-loader')
|
|
32
34
|
.loader('less-loader')
|
package/lib/apply-stylesheet.mjs
CHANGED
|
@@ -38,6 +38,7 @@ export async function applyStylesheet(chain) {
|
|
|
38
38
|
|
|
39
39
|
chain.module
|
|
40
40
|
.rule('style')
|
|
41
|
+
.after('esm')
|
|
41
42
|
.test(extToRegexp({ extname: ['css'] }))
|
|
42
43
|
.rule('all')
|
|
43
44
|
.oneOf('not-url')
|
|
@@ -79,7 +80,9 @@ export async function applyStylesheet(chain) {
|
|
|
79
80
|
},
|
|
80
81
|
});
|
|
81
82
|
|
|
82
|
-
if (
|
|
83
|
+
if (hot) {
|
|
84
|
+
parent.use('style-loader').loader('style-loader');
|
|
85
|
+
} else {
|
|
83
86
|
const { default: MiniCssExtractPlugin } = await import(
|
|
84
87
|
'mini-css-extract-plugin'
|
|
85
88
|
);
|
|
@@ -93,8 +96,6 @@ export async function applyStylesheet(chain) {
|
|
|
93
96
|
ignoreOrder: true,
|
|
94
97
|
},
|
|
95
98
|
]);
|
|
96
|
-
} else {
|
|
97
|
-
parent.use('style-loader').loader('style-loader');
|
|
98
99
|
}
|
|
99
100
|
|
|
100
101
|
if (!watch && chain.module.rules.has('babel')) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@best-shot/preset-style",
|
|
3
|
-
"version": "0.10.
|
|
3
|
+
"version": "0.10.6",
|
|
4
4
|
"description": "A `best-shot` preset for stylesheet",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": {
|
|
@@ -36,22 +36,22 @@
|
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"css-loader": "^6.7.3",
|
|
38
38
|
"css-minimizer-webpack-plugin": "^5.0.0",
|
|
39
|
-
"cssnano": "^6.0.
|
|
39
|
+
"cssnano": "^6.0.1",
|
|
40
40
|
"ext-to-regexp": "^0.1.0",
|
|
41
41
|
"less": "^4.1.3",
|
|
42
42
|
"less-loader": "^11.1.0",
|
|
43
43
|
"mini-css-extract-plugin": "^2.7.5",
|
|
44
|
-
"postcss": "^8.4.
|
|
45
|
-
"postcss-loader": "^7.
|
|
44
|
+
"postcss": "^8.4.23",
|
|
45
|
+
"postcss-loader": "^7.3.0",
|
|
46
46
|
"postcss-preset-evergreen": "^0.5.0",
|
|
47
47
|
"resolve-url-loader": "^5.0.0",
|
|
48
|
-
"sass": "^1.62.
|
|
48
|
+
"sass": "^1.62.1",
|
|
49
49
|
"sass-loader": "^13.2.2",
|
|
50
50
|
"slash-to-regexp": "^0.0.4",
|
|
51
51
|
"style-loader": "^3.3.2"
|
|
52
52
|
},
|
|
53
53
|
"peerDependencies": {
|
|
54
|
-
"@best-shot/core": "^0.7
|
|
54
|
+
"@best-shot/core": "^0.7"
|
|
55
55
|
},
|
|
56
56
|
"engines": {
|
|
57
57
|
"node": "^16.15.0 || ^18.12.0"
|