weboptimizer 3.0.15 → 3.0.16

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "weboptimizer",
3
- "version": "3.0.15",
3
+ "version": "3.0.16",
4
4
  "description": "A generic web optimizer, (module) bundler and development environment.",
5
5
  "keywords": [
6
6
  "webpack",
@@ -98,7 +98,7 @@
98
98
  "babel-loader": "^10.1.1",
99
99
  "babel-plugin-transform-modern-regexp": "^0.0.6",
100
100
  "babel-preset-minify": "^0.5.2",
101
- "clientnode": "4.0.1362",
101
+ "clientnode": "4.0.1364",
102
102
  "ejs": "^5.0.1",
103
103
  "exports-loader": "^5.0.0",
104
104
  "extract-loader": "^5.1.0",
@@ -614,6 +614,15 @@ var evaluateAdditionalLoaderConfiguration = function evaluateAdditionalLoaderCon
614
614
  var getIncludingPaths = function getIncludingPaths(path) {
615
615
  return (0, _helper.normalizePaths)([path].concat(_module.locations.directoryPaths));
616
616
  };
617
+ var postCSSResolver = function postCSSResolver(name, _context) {
618
+ for (var _i7 = 0, _Object$entries6 = Object.entries(configuration.module.aliases); _i7 < _Object$entries6.length; _i7++) {
619
+ var _Object$entries6$_i = (0, _slicedToArray2["default"])(_Object$entries6[_i7], 2),
620
+ source = _Object$entries6$_i[0],
621
+ target = _Object$entries6$_i[1];
622
+ if (source.startsWith(name)) return target;
623
+ }
624
+ return name;
625
+ };
617
626
  var cssUse = _module.preprocessor.cascadingStyleSheet.additional.pre.map(createEvaluateMapper('css')).concat({
618
627
  loader: _module.style.loader,
619
628
  options: _module.style.options || {}
@@ -630,7 +639,8 @@ var cssUse = _module.preprocessor.cascadingStyleSheet.additional.pre.map(createE
630
639
  consumer decide which distribution suites most.
631
640
  */
632
641
  plugins: [].concat(postcssImport ? postcssImport({
633
- root: configuration.path.context
642
+ root: configuration.path.context,
643
+ resolve: postCSSResolver
634
644
  }) : [], _module.preprocessor.cascadingStyleSheet.additional.plugins.pre.map(createEvaluateMapper('css.postcss')),
635
645
  /*
636
646
  NOTE: Checking path doesn't work if fonts
@@ -1106,8 +1116,8 @@ var webpackConfiguration = exports.webpackConfiguration = (0, _clientnode.extend
1106
1116
  cacheGroups: {
1107
1117
  defaultVendors: {
1108
1118
  chunks: function chunks(chunk) {
1109
- if (configuration.inPlace.javaScript) for (var _i7 = 0, _Object$keys = Object.keys(configuration.inPlace.javaScript); _i7 < _Object$keys.length; _i7++) {
1110
- var _name3 = _Object$keys[_i7];
1119
+ if (configuration.inPlace.javaScript) for (var _i8 = 0, _Object$keys = Object.keys(configuration.inPlace.javaScript); _i8 < _Object$keys.length; _i8++) {
1120
+ var _name3 = _Object$keys[_i8];
1111
1121
  if (_name3 === '*' || _name3 === chunk.name) return false;
1112
1122
  }
1113
1123
  return true;