@zohodesk/react-cli 1.0.2-exp.3 → 1.0.2-exp.4
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.
@@ -209,12 +209,11 @@ const getDevPlugins = (options, publicPath) => {
|
|
209
209
|
patterns,
|
210
210
|
patternsRootDir
|
211
211
|
}));
|
212
|
-
}
|
212
|
+
} // if (pluginObject.minifier) {
|
213
|
+
// // console.log('minifier active');
|
214
|
+
// pluginsArr.push(new MinifierPlugin());
|
215
|
+
// }
|
213
216
|
|
214
|
-
if (pluginObject.minifier) {
|
215
|
-
// console.log('minifier active');
|
216
|
-
pluginsArr.push(new _plugins.MinifierPlugin());
|
217
|
-
}
|
218
217
|
|
219
218
|
return pluginsArr.filter(Boolean);
|
220
219
|
};
|
@@ -45,12 +45,15 @@ const getProdPlugins = (options, publicPath = '') => {
|
|
45
45
|
bundleAnalyze,
|
46
46
|
optimize,
|
47
47
|
publicPaths,
|
48
|
+
patterns,
|
49
|
+
patternsRootDir,
|
48
50
|
hasEFC: prevOptionForEnableEFC,
|
49
51
|
enableSMapHook,
|
50
52
|
tpFolder,
|
51
53
|
folder,
|
52
54
|
outputFolder,
|
53
55
|
context,
|
56
|
+
exclude,
|
54
57
|
enableSMap,
|
55
58
|
server: {
|
56
59
|
mode
|
@@ -268,13 +271,18 @@ const getProdPlugins = (options, publicPath = '') => {
|
|
268
271
|
|
269
272
|
if (pluginObject.cssVariableReplacement) {
|
270
273
|
pluginsArr.push(new _VariableConversionCollector.default({
|
271
|
-
cssVariableReplacementConfig
|
274
|
+
cssVariableReplacementConfig,
|
275
|
+
patterns,
|
276
|
+
patternsRootDir
|
272
277
|
}));
|
273
278
|
}
|
274
279
|
|
275
280
|
if (pluginObject.selectorWeight) {
|
276
281
|
pluginsArr.push(new _SelectorPlugin.default({
|
277
|
-
selectorWeightConfig
|
282
|
+
selectorWeightConfig,
|
283
|
+
exclude: exclude.selectorWeight,
|
284
|
+
patterns,
|
285
|
+
patternsRootDir
|
278
286
|
}));
|
279
287
|
} // plugins.push(new VariableConversionCollector({}));
|
280
288
|
|
@@ -121,7 +121,8 @@ class VariableConversionCollector {
|
|
121
121
|
this.optimize = options.optimize;
|
122
122
|
this.filename = options.cssVariableReplacementConfig;
|
123
123
|
this.patterns = options.patterns;
|
124
|
-
this.rootDir = options.patternsRootDir;
|
124
|
+
this.rootDir = options.patternsRootDir; // console.log(options.patterns, this.patterns);
|
125
|
+
|
125
126
|
this.initializeFiles();
|
126
127
|
}
|
127
128
|
|