@angular/build 19.2.12 → 19.2.14
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 +3 -3
- package/src/builders/dev-server/vite-server.js +3 -6
- package/src/tools/esbuild/angular/compiler-plugin.d.ts +6 -0
- package/src/tools/esbuild/angular/compiler-plugin.js +2 -1
- package/src/tools/esbuild/javascript-transformer.js +4 -1
- package/src/utils/normalize-cache.js +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@angular/build",
|
|
3
|
-
"version": "19.2.
|
|
3
|
+
"version": "19.2.14",
|
|
4
4
|
"description": "Official build system for Angular",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Angular CLI",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"builders": "builders.json",
|
|
24
24
|
"dependencies": {
|
|
25
25
|
"@ampproject/remapping": "2.3.0",
|
|
26
|
-
"@angular-devkit/architect": "0.1902.
|
|
26
|
+
"@angular-devkit/architect": "0.1902.14",
|
|
27
27
|
"@babel/core": "7.26.10",
|
|
28
28
|
"@babel/helper-annotate-as-pure": "7.25.9",
|
|
29
29
|
"@babel/helper-split-export-declaration": "7.24.7",
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
"@angular/localize": "^19.0.0 || ^19.2.0-next.0",
|
|
59
59
|
"@angular/platform-server": "^19.0.0 || ^19.2.0-next.0",
|
|
60
60
|
"@angular/service-worker": "^19.0.0 || ^19.2.0-next.0",
|
|
61
|
-
"@angular/ssr": "^19.2.
|
|
61
|
+
"@angular/ssr": "^19.2.14",
|
|
62
62
|
"karma": "^6.4.0",
|
|
63
63
|
"less": "^4.2.0",
|
|
64
64
|
"ng-packagr": "^19.0.0 || ^19.2.0-next.0",
|
|
@@ -116,16 +116,13 @@ async function* serveWithVite(serverOptions, builderName, builderAction, context
|
|
|
116
116
|
}
|
|
117
117
|
// Enable to support link-based component style hot reloading (`NG_HMR_CSTYLES=1` can be used to enable)
|
|
118
118
|
browserOptions.externalRuntimeStyles =
|
|
119
|
-
serverOptions.liveReload && serverOptions.hmr && environment_options_1.useComponentStyleHmr;
|
|
119
|
+
browserOptions.aot && serverOptions.liveReload && serverOptions.hmr && environment_options_1.useComponentStyleHmr;
|
|
120
120
|
// Enable to support component template hot replacement (`NG_HMR_TEMPLATE=0` can be used to disable selectively)
|
|
121
121
|
// This will also replace file-based/inline styles as code if external runtime styles are not enabled.
|
|
122
122
|
browserOptions.templateUpdates =
|
|
123
|
-
serverOptions.liveReload && serverOptions.hmr && environment_options_1.useComponentTemplateHmr;
|
|
123
|
+
browserOptions.aot && serverOptions.liveReload && serverOptions.hmr && environment_options_1.useComponentTemplateHmr;
|
|
124
124
|
if (browserOptions.templateUpdates) {
|
|
125
|
-
context.logger.warn('Component HMR has been enabled
|
|
126
|
-
'If you encounter application reload issues, you can manually reload the page to bypass HMR and/or disable this feature with the' +
|
|
127
|
-
' `--no-hmr` command line option.\n' +
|
|
128
|
-
'Please consider reporting any issues you encounter here: https://github.com/angular/angular-cli/issues\n');
|
|
125
|
+
context.logger.warn('Component HMR has been enabled, see https://angular.dev/hmr for more info.');
|
|
129
126
|
}
|
|
130
127
|
browserOptions.incrementalResults = true;
|
|
131
128
|
// Setup the prebundling transformer that will be shared across Vite prebundling requests
|
|
@@ -14,6 +14,12 @@ export interface CompilerPluginOptions {
|
|
|
14
14
|
sourcemap: boolean | 'external';
|
|
15
15
|
tsconfig: string;
|
|
16
16
|
jit?: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* Include class metadata and JIT information in built code.
|
|
19
|
+
* The Angular TestBed APIs require additional metadata for the Angular aspects of the application
|
|
20
|
+
* such as Components, Modules, Pipes, etc.
|
|
21
|
+
* TestBed may also leverage JIT capabilities during testing (e.g., overrideComponent).
|
|
22
|
+
*/
|
|
17
23
|
includeTestMetadata?: boolean;
|
|
18
24
|
advancedOptimizations?: boolean;
|
|
19
25
|
thirdPartySourcemaps?: boolean;
|
|
@@ -89,7 +89,7 @@ function createCompilerPlugin(pluginOptions, compilationOrFactory, stylesheetBun
|
|
|
89
89
|
sourcemap: !!pluginOptions.sourcemap,
|
|
90
90
|
thirdPartySourcemaps: pluginOptions.thirdPartySourcemaps,
|
|
91
91
|
advancedOptimizations: pluginOptions.advancedOptimizations,
|
|
92
|
-
jit: pluginOptions.jit,
|
|
92
|
+
jit: pluginOptions.jit || pluginOptions.includeTestMetadata,
|
|
93
93
|
}, environment_options_1.maxWorkers, cacheStore?.createCache('jstransformer'));
|
|
94
94
|
// Setup defines based on the values used by the Angular compiler-cli
|
|
95
95
|
build.initialOptions.define ??= {};
|
|
@@ -552,6 +552,7 @@ function createCompilerOptionsTransformer(setupWarnings, pluginOptions, preserve
|
|
|
552
552
|
externalRuntimeStyles: pluginOptions.externalRuntimeStyles,
|
|
553
553
|
_enableHmr: !!pluginOptions.templateUpdates,
|
|
554
554
|
supportTestBed: !!pluginOptions.includeTestMetadata,
|
|
555
|
+
supportJitMode: !!pluginOptions.includeTestMetadata,
|
|
555
556
|
};
|
|
556
557
|
};
|
|
557
558
|
}
|
|
@@ -39,6 +39,9 @@ class JavaScriptTransformer {
|
|
|
39
39
|
this.#fileCacheKeyBase = Buffer.from(JSON.stringify(this.#commonOptions), 'utf-8');
|
|
40
40
|
}
|
|
41
41
|
#ensureWorkerPool() {
|
|
42
|
+
if (this.#workerPool) {
|
|
43
|
+
return this.#workerPool;
|
|
44
|
+
}
|
|
42
45
|
const workerPoolOptions = {
|
|
43
46
|
filename: require.resolve('./javascript-transformer-worker'),
|
|
44
47
|
maxThreads: this.maxThreads,
|
|
@@ -48,7 +51,7 @@ class JavaScriptTransformer {
|
|
|
48
51
|
if (process.execArgv.length !== filteredExecArgv.length) {
|
|
49
52
|
workerPoolOptions.execArgv = filteredExecArgv;
|
|
50
53
|
}
|
|
51
|
-
this.#workerPool
|
|
54
|
+
this.#workerPool = new worker_pool_1.WorkerPool(workerPoolOptions);
|
|
52
55
|
return this.#workerPool;
|
|
53
56
|
}
|
|
54
57
|
/**
|
|
@@ -10,7 +10,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
10
10
|
exports.normalizeCacheOptions = normalizeCacheOptions;
|
|
11
11
|
const node_path_1 = require("node:path");
|
|
12
12
|
/** Version placeholder is replaced during the build process with actual package version */
|
|
13
|
-
const VERSION = '19.2.
|
|
13
|
+
const VERSION = '19.2.14';
|
|
14
14
|
function hasCacheMetadata(value) {
|
|
15
15
|
return (!!value &&
|
|
16
16
|
typeof value === 'object' &&
|