@angular-devkit/build-angular 0.803.1 → 0.803.2
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 +7 -6
- package/src/angular-cli-files/models/es5-polyfills.js +3 -4
- package/src/angular-cli-files/models/webpack-configs/common.js +3 -1
- package/src/protractor/schema.d.ts +0 -1
- package/src/protractor/schema.json +1 -2
- package/src/utils/mangle-options.d.ts +1 -0
- package/src/utils/mangle-options.js +11 -0
- package/src/utils/process-bundle.js +4 -4
package/package.json
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@angular-devkit/build-angular",
|
|
3
|
-
"version": "0.803.
|
|
3
|
+
"version": "0.803.2",
|
|
4
4
|
"description": "Angular Webpack Build Facade",
|
|
5
5
|
"experimental": true,
|
|
6
6
|
"main": "src/index.js",
|
|
7
7
|
"typings": "src/index.d.ts",
|
|
8
8
|
"builders": "builders.json",
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@angular-devkit/architect": "0.803.
|
|
11
|
-
"@angular-devkit/build-optimizer": "0.803.
|
|
12
|
-
"@angular-devkit/build-webpack": "0.803.
|
|
13
|
-
"@angular-devkit/core": "8.3.
|
|
10
|
+
"@angular-devkit/architect": "0.803.2",
|
|
11
|
+
"@angular-devkit/build-optimizer": "0.803.2",
|
|
12
|
+
"@angular-devkit/build-webpack": "0.803.2",
|
|
13
|
+
"@angular-devkit/core": "8.3.2",
|
|
14
14
|
"@babel/core": "7.5.5",
|
|
15
15
|
"@babel/preset-env": "7.5.5",
|
|
16
|
-
"@ngtools/webpack": "8.3.
|
|
16
|
+
"@ngtools/webpack": "8.3.2",
|
|
17
17
|
"ajv": "6.10.2",
|
|
18
18
|
"autoprefixer": "9.6.1",
|
|
19
19
|
"browserslist": "4.6.6",
|
|
@@ -40,6 +40,7 @@
|
|
|
40
40
|
"postcss-import": "12.0.1",
|
|
41
41
|
"postcss-loader": "3.0.0",
|
|
42
42
|
"raw-loader": "3.1.0",
|
|
43
|
+
"regenerator-runtime": "0.13.3",
|
|
43
44
|
"rxjs": "6.4.0",
|
|
44
45
|
"sass": "1.22.9",
|
|
45
46
|
"sass-loader": "7.2.0",
|
|
@@ -7,10 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
// ES2015 symbol capabilities
|
|
10
|
-
import 'core-js/
|
|
11
|
-
import 'core-js/modules/es.symbol.description';
|
|
12
|
-
import 'core-js/modules/es.symbol.iterator';
|
|
13
|
-
import 'core-js/modules/es.symbol.to-string-tag';
|
|
10
|
+
import 'core-js/es/symbol';
|
|
14
11
|
|
|
15
12
|
// ES2015 function capabilities
|
|
16
13
|
import 'core-js/modules/es.function.bind';
|
|
@@ -103,3 +100,5 @@ import 'core-js/modules/web.dom-collections.for-each';
|
|
|
103
100
|
import 'core-js/modules/web.dom-collections.iterator';
|
|
104
101
|
import 'core-js/modules/es.promise';
|
|
105
102
|
import 'core-js/modules/es.json.to-string-tag';
|
|
103
|
+
|
|
104
|
+
import 'regenerator-runtime/runtime';
|
|
@@ -15,6 +15,7 @@ const typescript_1 = require("typescript");
|
|
|
15
15
|
const webpack_1 = require("webpack");
|
|
16
16
|
const webpack_sources_1 = require("webpack-sources");
|
|
17
17
|
const utils_1 = require("../../../utils");
|
|
18
|
+
const mangle_options_1 = require("../../../utils/mangle-options");
|
|
18
19
|
const bundle_budget_1 = require("../../plugins/bundle-budget");
|
|
19
20
|
const cleancss_webpack_plugin_1 = require("../../plugins/cleancss-webpack-plugin");
|
|
20
21
|
const named_chunks_plugin_1 = require("../../plugins/named-chunks-plugin");
|
|
@@ -281,7 +282,8 @@ function getCommonConfig(wco) {
|
|
|
281
282
|
},
|
|
282
283
|
// We also want to avoid mangling on server.
|
|
283
284
|
// Name mangling is handled within the browser builder
|
|
284
|
-
mangle:
|
|
285
|
+
mangle: !mangle_options_1.manglingDisabled &&
|
|
286
|
+
buildOptions.platform !== 'server' &&
|
|
285
287
|
(!differentialLoadingNeeded || (differentialLoadingNeeded && utils_1.fullDifferential)),
|
|
286
288
|
};
|
|
287
289
|
extraMinimizers.push(new TerserPlugin({
|
|
@@ -45,8 +45,7 @@
|
|
|
45
45
|
},
|
|
46
46
|
"baseUrl": {
|
|
47
47
|
"type": "string",
|
|
48
|
-
"description": "Base URL for protractor to connect to."
|
|
49
|
-
"x-deprecated": "Use \"baseUrl\" in the Protractor config file instead."
|
|
48
|
+
"description": "Base URL for protractor to connect to."
|
|
50
49
|
}
|
|
51
50
|
},
|
|
52
51
|
"additionalProperties": false,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const manglingDisabled: boolean;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
/**
|
|
4
|
+
* @license
|
|
5
|
+
* Copyright Google Inc. All Rights Reserved.
|
|
6
|
+
*
|
|
7
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
8
|
+
* found in the LICENSE file at https://angular.io/license
|
|
9
|
+
*/
|
|
10
|
+
const mangleVariable = process.env['NG_BUILD_MANGLE'];
|
|
11
|
+
exports.manglingDisabled = !!mangleVariable && (mangleVariable === '0' || mangleVariable.toLowerCase() === 'false');
|
|
@@ -11,6 +11,7 @@ const fs = require("fs");
|
|
|
11
11
|
const path = require("path");
|
|
12
12
|
const source_map_1 = require("source-map");
|
|
13
13
|
const terser_1 = require("terser");
|
|
14
|
+
const mangle_options_1 = require("./mangle-options");
|
|
14
15
|
const { transformAsync } = require('@babel/core');
|
|
15
16
|
const cacache = require('cacache');
|
|
16
17
|
function process(options, callback) {
|
|
@@ -92,11 +93,10 @@ async function processWorker(options) {
|
|
|
92
93
|
// estree -> terser is already supported; need babel -> estree/terser
|
|
93
94
|
// Mangle downlevel code
|
|
94
95
|
const result = terser_1.minify(code, {
|
|
95
|
-
compress:
|
|
96
|
+
compress: true,
|
|
96
97
|
ecma: 5,
|
|
97
|
-
mangle:
|
|
98
|
+
mangle: !mangle_options_1.manglingDisabled,
|
|
98
99
|
safari10: true,
|
|
99
|
-
toplevel: true,
|
|
100
100
|
output: {
|
|
101
101
|
ascii_only: true,
|
|
102
102
|
webkit: true,
|
|
@@ -137,7 +137,7 @@ async function mangleOriginal(options) {
|
|
|
137
137
|
const resultOriginal = terser_1.minify(options.code, {
|
|
138
138
|
compress: false,
|
|
139
139
|
ecma: 6,
|
|
140
|
-
mangle:
|
|
140
|
+
mangle: !mangle_options_1.manglingDisabled,
|
|
141
141
|
safari10: true,
|
|
142
142
|
output: {
|
|
143
143
|
ascii_only: true,
|