Skip to content

Commit 9bfe1a7

Browse files
author
Angular Builds
committed
d56c8de refactor: minor code cleanup to improve code health
1 parent f04c17a commit 9bfe1a7

File tree

6 files changed

+15
-11
lines changed

6 files changed

+15
-11
lines changed

package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
{
22
"name": "@angular-devkit/build-angular",
3-
"version": "18.1.0-next.3+sha-0d2d986",
3+
"version": "18.1.0-next.3+sha-d56c8de",
44
"description": "Angular Webpack Build Facade",
55
"main": "src/index.js",
66
"typings": "src/index.d.ts",
77
"builders": "builders.json",
88
"dependencies": {
99
"@ampproject/remapping": "2.3.0",
10-
"@angular-devkit/architect": "github:angular/angular-devkit-architect-builds#0d2d986",
11-
"@angular-devkit/build-webpack": "github:angular/angular-devkit-build-webpack-builds#0d2d986",
12-
"@angular-devkit/core": "github:angular/angular-devkit-core-builds#0d2d986",
13-
"@angular/build": "github:angular/angular-build-builds#0d2d986",
10+
"@angular-devkit/architect": "github:angular/angular-devkit-architect-builds#d56c8de",
11+
"@angular-devkit/build-webpack": "github:angular/angular-devkit-build-webpack-builds#d56c8de",
12+
"@angular-devkit/core": "github:angular/angular-devkit-core-builds#d56c8de",
13+
"@angular/build": "github:angular/angular-build-builds#d56c8de",
1414
"@babel/core": "7.24.7",
1515
"@babel/generator": "7.24.7",
1616
"@babel/helper-annotate-as-pure": "7.24.7",
@@ -21,7 +21,7 @@
2121
"@babel/preset-env": "7.24.7",
2222
"@babel/runtime": "7.24.7",
2323
"@discoveryjs/json-ext": "0.5.7",
24-
"@ngtools/webpack": "github:angular/ngtools-webpack-builds#0d2d986",
24+
"@ngtools/webpack": "github:angular/ngtools-webpack-builds#d56c8de",
2525
"@vitejs/plugin-basic-ssl": "1.1.0",
2626
"ansi-colors": "4.1.3",
2727
"autoprefixer": "10.4.19",

src/builders/dev-server/webpack-server.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ function serveWebpackBrowser(options, builderName, context, transforms = {}) {
7575
rawBrowserOptions.outputHashing = schema_1.OutputHashing.None;
7676
logger.warn(`Warning: 'outputHashing' option is disabled when using the dev-server.`);
7777
}
78+
// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-assertion
7879
const browserOptions = (await context.validateOptions({
7980
...rawBrowserOptions,
8081
watch: options.watch,

src/utils/normalize-cache.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
1010
exports.normalizeCacheOptions = normalizeCacheOptions;
1111
const node_path_1 = require("node:path");
1212
/** Version placeholder is replaced during the build process with actual package version */
13-
const VERSION = '18.1.0-next.3+sha-0d2d986';
13+
const VERSION = '18.1.0-next.3+sha-d56c8de';
1414
function hasCacheMetadata(value) {
1515
return (!!value &&
1616
typeof value === 'object' &&

src/utils/process-bundle.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ async function inlineLocales(options) {
145145
}
146146
}
147147
const { diagnostics: localeDiagnostics, plugins } = await createI18nPlugins(locale, translations, isSourceLocale ? 'ignore' : options.missingTranslation || 'warning', true, localeDataContent);
148-
const transformResult = await (0, core_1.transformFromAstSync)(ast, options.code, {
148+
const transformResult = (0, core_1.transformFromAstSync)(ast, options.code, {
149149
filename: options.filename,
150150
// using false ensures that babel will NOT search and process sourcemap comments (large memory usage)
151151
// The types do not include the false option even though it is valid

src/utils/run-module-as-observable-fork.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,15 @@
66
* Use of this source code is governed by an MIT-style license that can be
77
* found in the LICENSE file at https://angular.dev/license
88
*/
9+
var __importDefault = (this && this.__importDefault) || function (mod) {
10+
return (mod && mod.__esModule) ? mod : { "default": mod };
11+
};
912
Object.defineProperty(exports, "__esModule", { value: true });
1013
exports.runModuleAsObservableFork = runModuleAsObservableFork;
1114
const child_process_1 = require("child_process");
1215
const path_1 = require("path");
1316
const rxjs_1 = require("rxjs");
14-
const treeKill = require('tree-kill');
17+
const tree_kill_1 = __importDefault(require("tree-kill"));
1518
function runModuleAsObservableFork(cwd, modulePath, exportName,
1619
// eslint-disable-next-line @typescript-eslint/no-explicit-any
1720
args) {
@@ -39,7 +42,7 @@ args) {
3942
// Cleanup.
4043
const killForkedProcess = () => {
4144
if (forkedProcess && forkedProcess.pid) {
42-
treeKill(forkedProcess.pid, 'SIGTERM');
45+
(0, tree_kill_1.default)(forkedProcess.pid, 'SIGTERM');
4346
}
4447
};
4548
// Handle child process exit.

uniqueId

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Tue Jun 25 2024 19:25:00 GMT+0000 (Coordinated Universal Time)
1+
Tue Jun 25 2024 21:01:37 GMT+0000 (Coordinated Universal Time)

0 commit comments

Comments
 (0)