weboptimizer 2.0.1321 → 2.0.1323
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 +2 -2
- package/webpackConfigurator.js +6 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "weboptimizer",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1323",
|
|
4
4
|
"description": "A generic web optimizer, (module) bundler and development environment.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"webpack",
|
|
@@ -1188,7 +1188,7 @@
|
|
|
1188
1188
|
],
|
|
1189
1189
|
"presets": {
|
|
1190
1190
|
"#": "NOTE: We have to disable module export/import transformation to allow tree shaking by the final (minimizer).",
|
|
1191
|
-
"__evaluate__": "[['@babel/preset-env', {loose: true, modules: false, targets: self.generic.isWeb ? {browsers: self.generic.supportedBrowsers, node: packageConfiguration.engines.node} : {node: packageConfiguration.engines.node}}], '@babel/preset-typescript'].concat((self.debug || !self.module.optimizer.babelMinify.module || 2 < self.givenCommandLineArguments.length && self.givenCommandLineArguments[2] === 'document') ? [] : [['minify', self.module.optimizer.babelMinify.module]])"
|
|
1191
|
+
"__evaluate__": "[['@babel/preset-env', {loose: true, modules: false, targets: self.generic.isWeb ? {browsers: self.generic.supportedBrowsers, node: packageConfiguration.engines.node.replace(/>?=?([0-9]+)/, '$1')} : {node: packageConfiguration.engines.node.replace(/>?=?([0-9]+)/, '$1')}}], '@babel/preset-typescript'].concat((self.debug || !self.module.optimizer.babelMinify.module || 2 < self.givenCommandLineArguments.length && self.givenCommandLineArguments[2] === 'document') ? [] : [['minify', self.module.optimizer.babelMinify.module]])"
|
|
1192
1192
|
}
|
|
1193
1193
|
},
|
|
1194
1194
|
"regularExpression": "\\.[jt]sx?(?:\\?.*)?$"
|
package/webpackConfigurator.js
CHANGED
|
@@ -746,7 +746,9 @@ var evaluateAdditionalLoaderConfiguration = function evaluateAdditionalLoaderCon
|
|
|
746
746
|
use: evaluate(loaderConfiguration.use)
|
|
747
747
|
};
|
|
748
748
|
};
|
|
749
|
-
var
|
|
749
|
+
var getIncludingPaths = function getIncludingPaths(path) {
|
|
750
|
+
return _helper["default"].normalizePaths([path].concat(_module.locations.directoryPaths));
|
|
751
|
+
};
|
|
750
752
|
var cssUse = _module.preprocessor.cascadingStyleSheet.additional.pre.map(evaluateMapper).concat({
|
|
751
753
|
loader: _module.style.loader,
|
|
752
754
|
options: _module.style.options || {}
|
|
@@ -822,7 +824,7 @@ var genericLoader = {
|
|
|
822
824
|
return htmlConfiguration.template.filePath;
|
|
823
825
|
})).includes(filePath) || _module.preprocessor.ejs.exclude === null ? false : Boolean(evaluate(_module.preprocessor.ejs.exclude, filePath));
|
|
824
826
|
},
|
|
825
|
-
include:
|
|
827
|
+
include: getIncludingPaths(configuration.path.source.asset.template),
|
|
826
828
|
test: /^(?!.+\.html\.ejs$).+\.ejs$/i,
|
|
827
829
|
use: _module.preprocessor.ejs.additional.pre.map(evaluateMapper).concat({
|
|
828
830
|
loader: 'file?name=[path][name]' + ((_clientnode["default"].isPlainObject(_module.preprocessor.ejs.options) ? _module.preprocessor.ejs.options : {
|
|
@@ -844,7 +846,7 @@ var genericLoader = {
|
|
|
844
846
|
include: function include(filePath) {
|
|
845
847
|
var result = evaluate(_module.preprocessor.javaScript.include, filePath);
|
|
846
848
|
if ([null, undefined].includes(result)) {
|
|
847
|
-
var _iterator12 = _createForOfIteratorHelper(
|
|
849
|
+
var _iterator12 = _createForOfIteratorHelper(getIncludingPaths(configuration.path.source.asset.javaScript)),
|
|
848
850
|
_step12;
|
|
849
851
|
try {
|
|
850
852
|
for (_iterator12.s(); !(_step12 = _iterator12.n()).done;) {
|
|
@@ -926,7 +928,7 @@ var genericLoader = {
|
|
|
926
928
|
include: function include(filePath) {
|
|
927
929
|
var result = evaluate(_module.cascadingStyleSheet.include, filePath);
|
|
928
930
|
if ([null, undefined].includes(result)) {
|
|
929
|
-
var _iterator13 = _createForOfIteratorHelper(
|
|
931
|
+
var _iterator13 = _createForOfIteratorHelper(getIncludingPaths(configuration.path.source.asset.cascadingStyleSheet)),
|
|
930
932
|
_step13;
|
|
931
933
|
try {
|
|
932
934
|
for (_iterator13.s(); !(_step13 = _iterator13.n()).done;) {
|