@angular/build 18.1.0-next.0 → 18.1.0-next.1
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 +9 -9
- package/src/builders/application/build-action.js +1 -2
- package/src/builders/application/execute-build.js +1 -2
- package/src/builders/application/execute-post-bundle.js +1 -2
- package/src/builders/application/i18n.js +2 -3
- package/src/builders/application/index.js +2 -3
- package/src/builders/application/options.d.ts +2 -2
- package/src/builders/application/options.js +1 -2
- package/src/builders/application/setup-bundling.js +2 -8
- package/src/builders/dev-server/builder.d.ts +0 -1
- package/src/builders/dev-server/builder.js +1 -2
- package/src/builders/dev-server/options.d.ts +4 -0
- package/src/builders/dev-server/options.js +26 -2
- package/src/builders/dev-server/schema.d.ts +10 -0
- package/src/builders/dev-server/schema.json +11 -0
- package/src/builders/dev-server/vite-server.js +42 -34
- package/src/builders/extract-i18n/application-extraction.js +1 -2
- package/src/builders/extract-i18n/builder.js +1 -2
- package/src/builders/extract-i18n/options.js +1 -2
- package/src/tools/babel/plugins/adjust-static-class-members.d.ts +0 -1
- package/src/tools/babel/plugins/adjust-static-class-members.js +2 -3
- package/src/tools/babel/plugins/adjust-typescript-enums.d.ts +0 -1
- package/src/tools/babel/plugins/adjust-typescript-enums.js +2 -3
- package/src/tools/babel/plugins/elide-angular-metadata.d.ts +0 -1
- package/src/tools/babel/plugins/elide-angular-metadata.js +2 -3
- package/src/tools/babel/plugins/pure-toplevel-functions.d.ts +0 -1
- package/src/tools/babel/plugins/pure-toplevel-functions.js +1 -1
- package/src/tools/esbuild/angular/angular-host.js +2 -3
- package/src/tools/esbuild/angular/compilation/aot-compilation.js +42 -7
- package/src/tools/esbuild/angular/compilation/factory.js +1 -2
- package/src/tools/esbuild/angular/compilation/jit-bootstrap-transformer.js +2 -3
- package/src/tools/esbuild/angular/compilation/parallel-worker.d.ts +2 -1
- package/src/tools/esbuild/angular/compilation/parallel-worker.js +10 -7
- package/src/tools/esbuild/angular/compilation-state.js +2 -2
- package/src/tools/esbuild/angular/compiler-plugin.js +18 -9
- package/src/tools/esbuild/angular/diagnostics.js +1 -2
- package/src/tools/esbuild/angular/jit-plugin-callbacks.js +1 -2
- package/src/tools/esbuild/angular/jit-resource-transformer.js +1 -2
- package/src/tools/esbuild/angular/uri.js +4 -4
- package/src/tools/esbuild/angular/web-worker-transformer.js +1 -2
- package/src/tools/esbuild/application-code-bundle.js +4 -5
- package/src/tools/esbuild/budget-stats.js +1 -2
- package/src/tools/esbuild/commonjs-checker.js +1 -2
- package/src/tools/esbuild/compiler-plugin-options.js +1 -2
- package/src/tools/esbuild/external-packages-plugin.js +1 -2
- package/src/tools/esbuild/global-scripts.js +1 -2
- package/src/tools/esbuild/global-styles.js +1 -2
- package/src/tools/esbuild/i18n-inliner-worker.d.ts +1 -1
- package/src/tools/esbuild/i18n-inliner-worker.js +1 -1
- package/src/tools/esbuild/i18n-locale-plugin.js +2 -2
- package/src/tools/esbuild/index-html-generator.js +1 -2
- package/src/tools/esbuild/javascript-transformer-worker.js +1 -1
- package/src/tools/esbuild/javascript-transformer.d.ts +1 -1
- package/src/tools/esbuild/license-extractor.js +1 -2
- package/src/tools/esbuild/load-result-cache.js +2 -2
- package/src/tools/esbuild/profiling.js +4 -5
- package/src/tools/esbuild/rxjs-esm-resolution-plugin.js +1 -2
- package/src/tools/esbuild/sourcemap-ignorelist-plugin.js +1 -2
- package/src/tools/esbuild/stylesheets/bundle-options.js +1 -2
- package/src/tools/esbuild/stylesheets/css-inline-fonts-plugin.js +1 -2
- package/src/tools/esbuild/stylesheets/css-resource-plugin.js +1 -2
- package/src/tools/esbuild/stylesheets/sass-language.js +29 -3
- package/src/tools/esbuild/utils.js +15 -16
- package/src/tools/esbuild/virtual-module-plugin.js +1 -2
- package/src/tools/esbuild/watcher.js +2 -2
- package/src/tools/sass/lexer.js +1 -2
- package/src/tools/sass/rebasing-importer.js +2 -2
- package/src/tools/sass/sass-service.js +3 -1
- package/src/tools/sass/worker.d.ts +2 -4
- package/src/tools/sass/worker.js +1 -1
- package/src/tools/vite/angular-memory-plugin.js +1 -2
- package/src/tools/vite/i18n-locale-plugin.js +2 -2
- package/src/utils/bundle-calculator.js +4 -4
- package/src/utils/check-port.js +1 -2
- package/src/utils/delete-output-dir.js +1 -2
- package/src/utils/error.js +1 -2
- package/src/utils/format-bytes.js +1 -2
- package/src/utils/i18n-options.js +2 -3
- package/src/utils/index-file/add-event-dispatch-contract.js +1 -2
- package/src/utils/index-file/augment-index-html.js +1 -2
- package/src/utils/index-file/html-rewriting-stream.js +1 -2
- package/src/utils/index-file/nonce.js +1 -2
- package/src/utils/load-esm.js +1 -2
- package/src/utils/load-proxy-config.js +1 -2
- package/src/utils/load-translations.js +1 -2
- package/src/utils/normalize-asset-patterns.js +2 -2
- package/src/utils/normalize-cache.js +2 -3
- package/src/utils/normalize-optimization.js +1 -2
- package/src/utils/normalize-source-maps.js +1 -2
- package/src/utils/postcss-configuration.js +3 -4
- package/src/utils/purge-cache.js +1 -2
- package/src/utils/resolve-assets.js +1 -2
- package/src/utils/server-rendering/esm-in-memory-loader/loader-hooks.js +3 -4
- package/src/utils/server-rendering/fetch-patch.js +1 -2
- package/src/utils/server-rendering/load-esm-from-memory.js +1 -2
- package/src/utils/server-rendering/prerender.js +1 -2
- package/src/utils/server-rendering/render-page.js +1 -2
- package/src/utils/service-worker.d.ts +0 -2
- package/src/utils/service-worker.js +3 -4
- package/src/utils/stats-table.js +2 -3
- package/src/utils/supported-browsers.js +1 -2
- package/src/utils/tty.js +1 -2
- package/src/utils/url.js +1 -2
- package/src/utils/version.js +1 -2
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
* Use of this source code is governed by an MIT-style license that can be
|
|
6
6
|
* found in the LICENSE file at https://angular.io/license
|
|
7
7
|
*/
|
|
8
|
-
/// <reference types="@angular/compiler-cli/private/babel" />
|
|
9
8
|
import type { PluginObj } from '@babel/core';
|
|
10
9
|
/**
|
|
11
10
|
* A babel plugin factory function for adding the PURE annotation to top-level new and call expressions.
|
|
@@ -33,6 +33,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
33
33
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
34
34
|
};
|
|
35
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.default = default_1;
|
|
36
37
|
const helper_annotate_as_pure_1 = __importDefault(require("@babel/helper-annotate-as-pure"));
|
|
37
38
|
const tslib = __importStar(require("tslib"));
|
|
38
39
|
/**
|
|
@@ -87,4 +88,3 @@ function default_1() {
|
|
|
87
88
|
},
|
|
88
89
|
};
|
|
89
90
|
}
|
|
90
|
-
exports.default = default_1;
|
|
@@ -10,7 +10,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.
|
|
13
|
+
exports.ensureSourceFileVersions = ensureSourceFileVersions;
|
|
14
|
+
exports.createAngularCompilerHost = createAngularCompilerHost;
|
|
14
15
|
const node_crypto_1 = require("node:crypto");
|
|
15
16
|
const node_path_1 = __importDefault(require("node:path"));
|
|
16
17
|
/**
|
|
@@ -32,7 +33,6 @@ function ensureSourceFileVersions(program) {
|
|
|
32
33
|
return files;
|
|
33
34
|
};
|
|
34
35
|
}
|
|
35
|
-
exports.ensureSourceFileVersions = ensureSourceFileVersions;
|
|
36
36
|
function augmentHostWithCaching(host, cache) {
|
|
37
37
|
const baseGetSourceFile = host.getSourceFile;
|
|
38
38
|
host.getSourceFile = function (fileName, languageVersion, onError, shouldCreateNewSourceFile, ...parameters) {
|
|
@@ -131,4 +131,3 @@ function createAngularCompilerHost(typescript, compilerOptions, hostOptions) {
|
|
|
131
131
|
}
|
|
132
132
|
return host;
|
|
133
133
|
}
|
|
134
|
-
exports.createAngularCompilerHost = createAngularCompilerHost;
|
|
@@ -133,8 +133,10 @@ class AotCompilation extends angular_compilation_1.AngularCompilation {
|
|
|
133
133
|
}
|
|
134
134
|
emitAffectedFiles() {
|
|
135
135
|
(0, node_assert_1.default)(this.#state, 'Angular compilation must be initialized prior to emitting files.');
|
|
136
|
-
const { angularCompiler, compilerHost, typeScriptProgram, webWorkerTransform } = this.#state;
|
|
137
|
-
const
|
|
136
|
+
const { affectedFiles, angularCompiler, compilerHost, typeScriptProgram, webWorkerTransform } = this.#state;
|
|
137
|
+
const compilerOptions = typeScriptProgram.getCompilerOptions();
|
|
138
|
+
const buildInfoFilename = compilerOptions.tsBuildInfoFile ?? '.tsbuildinfo';
|
|
139
|
+
const useTypeScriptTranspilation = !compilerOptions.isolatedModules || !!compilerOptions.sourceMap;
|
|
138
140
|
const emittedFiles = new Map();
|
|
139
141
|
const writeFileCallback = (filename, contents, _a, _b, sourceFiles) => {
|
|
140
142
|
if (!sourceFiles?.length && filename.endsWith(buildInfoFilename)) {
|
|
@@ -154,9 +156,20 @@ class AotCompilation extends angular_compilation_1.AngularCompilation {
|
|
|
154
156
|
transformers.before ??= [];
|
|
155
157
|
transformers.before.push((0, jit_bootstrap_transformer_1.replaceBootstrap)(() => typeScriptProgram.getProgram().getTypeChecker()));
|
|
156
158
|
transformers.before.push(webWorkerTransform);
|
|
157
|
-
//
|
|
158
|
-
|
|
159
|
-
|
|
159
|
+
// Emit is handled in write file callback when using TypeScript
|
|
160
|
+
if (useTypeScriptTranspilation) {
|
|
161
|
+
// TypeScript will loop until there are no more affected files in the program
|
|
162
|
+
while (typeScriptProgram.emitNextAffectedFile(writeFileCallback, undefined, undefined, transformers)) {
|
|
163
|
+
/* empty */
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
else if (compilerOptions.tsBuildInfoFile) {
|
|
167
|
+
// Manually get the builder state for the persistent cache
|
|
168
|
+
// The TypeScript API currently embeds this behavior inside the program emit
|
|
169
|
+
// via emitNextAffectedFile but that also applies all internal transforms.
|
|
170
|
+
const programWithGetState = typeScriptProgram.getProgram();
|
|
171
|
+
(0, node_assert_1.default)(typeof programWithGetState.emitBuildInfo === 'function', 'TypeScript program emitBuildInfo is missing.');
|
|
172
|
+
programWithGetState.emitBuildInfo();
|
|
160
173
|
}
|
|
161
174
|
// Angular may have files that must be emitted but TypeScript does not consider affected
|
|
162
175
|
for (const sourceFile of typeScriptProgram.getSourceFiles()) {
|
|
@@ -166,10 +179,32 @@ class AotCompilation extends angular_compilation_1.AngularCompilation {
|
|
|
166
179
|
if (sourceFile.isDeclarationFile) {
|
|
167
180
|
continue;
|
|
168
181
|
}
|
|
169
|
-
if (angularCompiler.incrementalCompilation.safeToSkipEmit(sourceFile)
|
|
182
|
+
if (angularCompiler.incrementalCompilation.safeToSkipEmit(sourceFile) &&
|
|
183
|
+
!affectedFiles.has(sourceFile)) {
|
|
170
184
|
continue;
|
|
171
185
|
}
|
|
172
|
-
|
|
186
|
+
if (useTypeScriptTranspilation) {
|
|
187
|
+
typeScriptProgram.emit(sourceFile, writeFileCallback, undefined, undefined, transformers);
|
|
188
|
+
continue;
|
|
189
|
+
}
|
|
190
|
+
// When not using TypeScript transpilation, directly apply only Angular specific transformations
|
|
191
|
+
const transformResult = typescript_1.default.transform(sourceFile, [
|
|
192
|
+
...(transformers.before ?? []),
|
|
193
|
+
...(transformers.after ?? []),
|
|
194
|
+
], compilerOptions);
|
|
195
|
+
(0, node_assert_1.default)(transformResult.transformed.length === 1, 'TypeScript transforms should not produce multiple outputs for ' + sourceFile.fileName);
|
|
196
|
+
let contents;
|
|
197
|
+
if (sourceFile === transformResult.transformed[0]) {
|
|
198
|
+
// Use original content if no changes were made
|
|
199
|
+
contents = sourceFile.text;
|
|
200
|
+
}
|
|
201
|
+
else {
|
|
202
|
+
// Otherwise, print the transformed source file
|
|
203
|
+
const printer = typescript_1.default.createPrinter(compilerOptions, transformResult);
|
|
204
|
+
contents = printer.printFile(transformResult.transformed[0]);
|
|
205
|
+
}
|
|
206
|
+
angularCompiler.incrementalCompilation.recordSuccessfulEmit(sourceFile);
|
|
207
|
+
emittedFiles.set(sourceFile, { filename: sourceFile.fileName, contents });
|
|
173
208
|
}
|
|
174
209
|
return emittedFiles.values();
|
|
175
210
|
}
|
|
@@ -30,7 +30,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
30
30
|
return result;
|
|
31
31
|
};
|
|
32
32
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
33
|
-
exports.createAngularCompilation =
|
|
33
|
+
exports.createAngularCompilation = createAngularCompilation;
|
|
34
34
|
const environment_options_1 = require("../../../../utils/environment-options");
|
|
35
35
|
/**
|
|
36
36
|
* Creates an Angular compilation object that can be used to perform Angular application
|
|
@@ -53,4 +53,3 @@ async function createAngularCompilation(jit) {
|
|
|
53
53
|
return new AotCompilation();
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
|
-
exports.createAngularCompilation = createAngularCompilation;
|
|
@@ -10,7 +10,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.
|
|
13
|
+
exports.replaceBootstrap = replaceBootstrap;
|
|
14
|
+
exports.elideImports = elideImports;
|
|
14
15
|
const typescript_1 = __importDefault(require("typescript"));
|
|
15
16
|
/**
|
|
16
17
|
* The name of the Angular platform that should be replaced within
|
|
@@ -57,7 +58,6 @@ function replaceBootstrap(getTypeChecker) {
|
|
|
57
58
|
};
|
|
58
59
|
};
|
|
59
60
|
}
|
|
60
|
-
exports.replaceBootstrap = replaceBootstrap;
|
|
61
61
|
// Remove imports for which all identifiers have been removed.
|
|
62
62
|
// Needs type checker, and works even if it's not the first transformer.
|
|
63
63
|
// Works by removing imports for symbols whose identifiers have all been removed.
|
|
@@ -179,4 +179,3 @@ function elideImports(sourceFile, removedNodes, getTypeChecker, compilerOptions)
|
|
|
179
179
|
}
|
|
180
180
|
return importNodeRemovals;
|
|
181
181
|
}
|
|
182
|
-
exports.elideImports = elideImports;
|
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
* Use of this source code is governed by an MIT-style license that can be
|
|
6
6
|
* found in the LICENSE file at https://angular.io/license
|
|
7
7
|
*/
|
|
8
|
-
/// <reference types="node" />
|
|
9
8
|
import type { PartialMessage } from 'esbuild';
|
|
10
9
|
import { type MessagePort } from 'node:worker_threads';
|
|
11
10
|
import type { DiagnosticModes } from './angular-compilation';
|
|
@@ -23,6 +22,8 @@ export declare function initialize(request: InitRequest): Promise<{
|
|
|
23
22
|
referencedFiles: readonly string[];
|
|
24
23
|
compilerOptions: {
|
|
25
24
|
allowJs: boolean | undefined;
|
|
25
|
+
isolatedModules: boolean | undefined;
|
|
26
|
+
sourceMap: boolean | undefined;
|
|
26
27
|
};
|
|
27
28
|
}>;
|
|
28
29
|
export declare function diagnose(modes: DiagnosticModes): Promise<{
|
|
@@ -10,7 +10,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.
|
|
13
|
+
exports.initialize = initialize;
|
|
14
|
+
exports.diagnose = diagnose;
|
|
15
|
+
exports.emit = emit;
|
|
16
|
+
exports.update = update;
|
|
14
17
|
const node_assert_1 = __importDefault(require("node:assert"));
|
|
15
18
|
const node_crypto_1 = require("node:crypto");
|
|
16
19
|
const node_worker_threads_1 = require("node:worker_threads");
|
|
@@ -67,24 +70,24 @@ async function initialize(request) {
|
|
|
67
70
|
});
|
|
68
71
|
return {
|
|
69
72
|
referencedFiles,
|
|
70
|
-
// TODO: Expand? `allowJs`
|
|
71
|
-
compilerOptions: {
|
|
73
|
+
// TODO: Expand? `allowJs`, `isolatedModules`, `sourceMap` are the only fields needed currently.
|
|
74
|
+
compilerOptions: {
|
|
75
|
+
allowJs: compilerOptions.allowJs,
|
|
76
|
+
isolatedModules: compilerOptions.isolatedModules,
|
|
77
|
+
sourceMap: compilerOptions.sourceMap,
|
|
78
|
+
},
|
|
72
79
|
};
|
|
73
80
|
}
|
|
74
|
-
exports.initialize = initialize;
|
|
75
81
|
async function diagnose(modes) {
|
|
76
82
|
(0, node_assert_1.default)(compilation);
|
|
77
83
|
const diagnostics = await compilation.diagnoseFiles(modes);
|
|
78
84
|
return diagnostics;
|
|
79
85
|
}
|
|
80
|
-
exports.diagnose = diagnose;
|
|
81
86
|
async function emit() {
|
|
82
87
|
(0, node_assert_1.default)(compilation);
|
|
83
88
|
const files = await compilation.emitAffectedFiles();
|
|
84
89
|
return [...files];
|
|
85
90
|
}
|
|
86
|
-
exports.emit = emit;
|
|
87
91
|
function update(files) {
|
|
88
92
|
sourceFileCache.invalidate(files);
|
|
89
93
|
}
|
|
90
|
-
exports.update = update;
|
|
@@ -7,7 +7,8 @@
|
|
|
7
7
|
* found in the LICENSE file at https://angular.io/license
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.
|
|
10
|
+
exports.SharedTSCompilationState = void 0;
|
|
11
|
+
exports.getSharedCompilationState = getSharedCompilationState;
|
|
11
12
|
class SharedTSCompilationState {
|
|
12
13
|
#pendingCompilation = true;
|
|
13
14
|
#resolveCompilationReady;
|
|
@@ -41,4 +42,3 @@ let globalSharedCompilationState;
|
|
|
41
42
|
function getSharedCompilationState() {
|
|
42
43
|
return (globalSharedCompilationState ??= new SharedTSCompilationState());
|
|
43
44
|
}
|
|
44
|
-
exports.getSharedCompilationState = getSharedCompilationState;
|
|
@@ -33,7 +33,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
33
33
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
34
34
|
};
|
|
35
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
-
exports.createCompilerPlugin =
|
|
36
|
+
exports.createCompilerPlugin = createCompilerPlugin;
|
|
37
37
|
const node_assert_1 = __importDefault(require("node:assert"));
|
|
38
38
|
const path = __importStar(require("node:path"));
|
|
39
39
|
const environment_options_1 = require("../../../utils/environment-options");
|
|
@@ -53,9 +53,10 @@ function createCompilerPlugin(pluginOptions, styleOptions) {
|
|
|
53
53
|
async setup(build) {
|
|
54
54
|
let setupWarnings = [];
|
|
55
55
|
const preserveSymlinks = build.initialOptions.preserveSymlinks;
|
|
56
|
-
// Initialize a worker pool for JavaScript transformations
|
|
56
|
+
// Initialize a worker pool for JavaScript transformations.
|
|
57
|
+
// Webcontainers currently do not support this persistent cache store.
|
|
57
58
|
let cacheStore;
|
|
58
|
-
if (pluginOptions.sourceFileCache?.persistentCachePath) {
|
|
59
|
+
if (pluginOptions.sourceFileCache?.persistentCachePath && !process.versions.webcontainer) {
|
|
59
60
|
const { LmbdCacheStore } = await Promise.resolve().then(() => __importStar(require('../lmdb-cache-store')));
|
|
60
61
|
cacheStore = new LmbdCacheStore(path.join(pluginOptions.sourceFileCache.persistentCachePath, 'angular-compiler.db'));
|
|
61
62
|
}
|
|
@@ -77,6 +78,8 @@ function createCompilerPlugin(pluginOptions, styleOptions) {
|
|
|
77
78
|
let hasCompilationErrors = true;
|
|
78
79
|
// Determines if TypeScript should process JavaScript files based on tsconfig `allowJs` option
|
|
79
80
|
let shouldTsIgnoreJs = true;
|
|
81
|
+
// Determines if transpilation should be handle by TypeScript or esbuild
|
|
82
|
+
let useTypeScriptTranspilation = true;
|
|
80
83
|
// Track incremental component stylesheet builds
|
|
81
84
|
const stylesheetBundler = new component_stylesheets_1.ComponentStylesheetBundler(styleOptions, pluginOptions.incremental);
|
|
82
85
|
let sharedTSCompilationState;
|
|
@@ -179,6 +182,11 @@ function createCompilerPlugin(pluginOptions, styleOptions) {
|
|
|
179
182
|
try {
|
|
180
183
|
const initializationResult = await compilation.initialize(pluginOptions.tsconfig, hostOptions, createCompilerOptionsTransformer(setupWarnings, pluginOptions, preserveSymlinks));
|
|
181
184
|
shouldTsIgnoreJs = !initializationResult.compilerOptions.allowJs;
|
|
185
|
+
// Isolated modules option ensures safe non-TypeScript transpilation.
|
|
186
|
+
// Typescript printing support for sourcemaps is not yet integrated.
|
|
187
|
+
useTypeScriptTranspilation =
|
|
188
|
+
!initializationResult.compilerOptions.isolatedModules ||
|
|
189
|
+
!!initializationResult.compilerOptions.sourceMap;
|
|
182
190
|
referencedFiles = initializationResult.referencedFiles;
|
|
183
191
|
}
|
|
184
192
|
catch (error) {
|
|
@@ -249,8 +257,9 @@ function createCompilerPlugin(pluginOptions, styleOptions) {
|
|
|
249
257
|
});
|
|
250
258
|
build.onLoad({ filter: /\.[cm]?[jt]sx?$/ }, async (args) => {
|
|
251
259
|
const request = path.normalize(pluginOptions.fileReplacements?.[path.normalize(args.path)] ?? args.path);
|
|
260
|
+
const isJS = /\.[cm]?js$/.test(request);
|
|
252
261
|
// Skip TS load attempt if JS TypeScript compilation not enabled and file is JS
|
|
253
|
-
if (shouldTsIgnoreJs &&
|
|
262
|
+
if (shouldTsIgnoreJs && isJS) {
|
|
254
263
|
return undefined;
|
|
255
264
|
}
|
|
256
265
|
// The filename is currently used as a cache key. Since the cache is memory only,
|
|
@@ -266,7 +275,7 @@ function createCompilerPlugin(pluginOptions, styleOptions) {
|
|
|
266
275
|
}
|
|
267
276
|
// No TS result indicates the file is not part of the TypeScript program.
|
|
268
277
|
// If allowJs is enabled and the file is JS then defer to the next load hook.
|
|
269
|
-
if (!shouldTsIgnoreJs &&
|
|
278
|
+
if (!shouldTsIgnoreJs && isJS) {
|
|
270
279
|
return undefined;
|
|
271
280
|
}
|
|
272
281
|
// Otherwise return an error
|
|
@@ -276,8 +285,9 @@ function createCompilerPlugin(pluginOptions, styleOptions) {
|
|
|
276
285
|
],
|
|
277
286
|
};
|
|
278
287
|
}
|
|
279
|
-
else if (typeof contents === 'string') {
|
|
280
|
-
// A string indicates untransformed output from the TS/NG compiler
|
|
288
|
+
else if (typeof contents === 'string' && (useTypeScriptTranspilation || isJS)) {
|
|
289
|
+
// A string indicates untransformed output from the TS/NG compiler.
|
|
290
|
+
// This step is unneeded when using esbuild transpilation.
|
|
281
291
|
const sideEffects = await hasSideEffects(request);
|
|
282
292
|
contents = await javascriptTransformer.transformData(request, contents, true /* skipLinker */, sideEffects);
|
|
283
293
|
// Store as the returned Uint8Array to allow caching the fully transformed code
|
|
@@ -285,7 +295,7 @@ function createCompilerPlugin(pluginOptions, styleOptions) {
|
|
|
285
295
|
}
|
|
286
296
|
return {
|
|
287
297
|
contents,
|
|
288
|
-
loader: 'js',
|
|
298
|
+
loader: useTypeScriptTranspilation || isJS ? 'js' : 'ts',
|
|
289
299
|
};
|
|
290
300
|
});
|
|
291
301
|
build.onLoad({ filter: /\.[cm]?js$/ }, (0, load_result_cache_1.createCachedLoad)(pluginOptions.loadResultCache, async (args) => {
|
|
@@ -343,7 +353,6 @@ function createCompilerPlugin(pluginOptions, styleOptions) {
|
|
|
343
353
|
},
|
|
344
354
|
};
|
|
345
355
|
}
|
|
346
|
-
exports.createCompilerPlugin = createCompilerPlugin;
|
|
347
356
|
function createCompilerOptionsTransformer(setupWarnings, pluginOptions, preserveSymlinks) {
|
|
348
357
|
return (compilerOptions) => {
|
|
349
358
|
// target of 9 is ES2022 (using the number avoids an expensive import of typescript just for an enum)
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* found in the LICENSE file at https://angular.io/license
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.convertTypeScriptDiagnostic =
|
|
10
|
+
exports.convertTypeScriptDiagnostic = convertTypeScriptDiagnostic;
|
|
11
11
|
const node_os_1 = require("node:os");
|
|
12
12
|
/**
|
|
13
13
|
* Converts TypeScript Diagnostic related information into an esbuild compatible note object.
|
|
@@ -66,4 +66,3 @@ function convertTypeScriptDiagnostic(typescript, diagnostic) {
|
|
|
66
66
|
}
|
|
67
67
|
return message;
|
|
68
68
|
}
|
|
69
|
-
exports.convertTypeScriptDiagnostic = convertTypeScriptDiagnostic;
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* found in the LICENSE file at https://angular.io/license
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.setupJitPluginCallbacks =
|
|
10
|
+
exports.setupJitPluginCallbacks = setupJitPluginCallbacks;
|
|
11
11
|
const promises_1 = require("node:fs/promises");
|
|
12
12
|
const node_path_1 = require("node:path");
|
|
13
13
|
const load_result_cache_1 = require("../load-result-cache");
|
|
@@ -114,4 +114,3 @@ function setupJitPluginCallbacks(build, stylesheetBundler, additionalResultFiles
|
|
|
114
114
|
};
|
|
115
115
|
}));
|
|
116
116
|
}
|
|
117
|
-
exports.setupJitPluginCallbacks = setupJitPluginCallbacks;
|
|
@@ -10,7 +10,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.createJitResourceTransformer =
|
|
13
|
+
exports.createJitResourceTransformer = createJitResourceTransformer;
|
|
14
14
|
const typescript_1 = __importDefault(require("typescript"));
|
|
15
15
|
const uri_1 = require("./uri");
|
|
16
16
|
/**
|
|
@@ -50,7 +50,6 @@ function createJitResourceTransformer(getTypeChecker) {
|
|
|
50
50
|
};
|
|
51
51
|
};
|
|
52
52
|
}
|
|
53
|
-
exports.createJitResourceTransformer = createJitResourceTransformer;
|
|
54
53
|
function visitDecorator(nodeFactory, node, typeChecker, resourceImportDeclarations) {
|
|
55
54
|
const origin = getDecoratorOrigin(node, typeChecker);
|
|
56
55
|
if (!origin || origin.module !== '@angular/core' || origin.name !== 'Component') {
|
|
@@ -7,7 +7,10 @@
|
|
|
7
7
|
* found in the LICENSE file at https://angular.io/license
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.
|
|
10
|
+
exports.JIT_NAMESPACE_REGEXP = exports.JIT_TEMPLATE_NAMESPACE = exports.JIT_STYLE_NAMESPACE = void 0;
|
|
11
|
+
exports.generateJitFileUri = generateJitFileUri;
|
|
12
|
+
exports.generateJitInlineUri = generateJitInlineUri;
|
|
13
|
+
exports.parseJitUri = parseJitUri;
|
|
11
14
|
/**
|
|
12
15
|
* A string value representing the base namespace for Angular JIT mode related imports.
|
|
13
16
|
*/
|
|
@@ -39,7 +42,6 @@ exports.JIT_NAMESPACE_REGEXP = new RegExp(`^${JIT_BASE_NAMESPACE}:(template|styl
|
|
|
39
42
|
function generateJitFileUri(file, type) {
|
|
40
43
|
return `${JIT_BASE_NAMESPACE}:${type}:file;${file}`;
|
|
41
44
|
}
|
|
42
|
-
exports.generateJitFileUri = generateJitFileUri;
|
|
43
45
|
/**
|
|
44
46
|
* Generates an Angular JIT mode namespace URI for a given inline style or template.
|
|
45
47
|
* The provided content is base64 encoded and included in the URI.
|
|
@@ -50,7 +52,6 @@ exports.generateJitFileUri = generateJitFileUri;
|
|
|
50
52
|
function generateJitInlineUri(data, type) {
|
|
51
53
|
return `${JIT_BASE_NAMESPACE}:${type}:inline;${Buffer.from(data).toString('base64')}`;
|
|
52
54
|
}
|
|
53
|
-
exports.generateJitInlineUri = generateJitInlineUri;
|
|
54
55
|
/**
|
|
55
56
|
* Parses a string containing a JIT namespace URI.
|
|
56
57
|
* JIT namespace URIs are used to encode the information for an Angular component's stylesheets
|
|
@@ -71,4 +72,3 @@ function parseJitUri(uri) {
|
|
|
71
72
|
specifier: matches[3],
|
|
72
73
|
};
|
|
73
74
|
}
|
|
74
|
-
exports.parseJitUri = parseJitUri;
|
|
@@ -10,7 +10,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.createWorkerTransformer =
|
|
13
|
+
exports.createWorkerTransformer = createWorkerTransformer;
|
|
14
14
|
const typescript_1 = __importDefault(require("typescript"));
|
|
15
15
|
/**
|
|
16
16
|
* Creates a TypeScript Transformer to process Worker and SharedWorker entry points and transform
|
|
@@ -91,4 +91,3 @@ function createWorkerTransformer(fileProcessor) {
|
|
|
91
91
|
};
|
|
92
92
|
};
|
|
93
93
|
}
|
|
94
|
-
exports.createWorkerTransformer = createWorkerTransformer;
|
|
@@ -10,7 +10,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.
|
|
13
|
+
exports.createBrowserCodeBundleOptions = createBrowserCodeBundleOptions;
|
|
14
|
+
exports.createBrowserPolyfillBundleOptions = createBrowserPolyfillBundleOptions;
|
|
15
|
+
exports.createServerCodeBundleOptions = createServerCodeBundleOptions;
|
|
16
|
+
exports.createServerPolyfillBundleOptions = createServerPolyfillBundleOptions;
|
|
14
17
|
const node_assert_1 = __importDefault(require("node:assert"));
|
|
15
18
|
const node_crypto_1 = require("node:crypto");
|
|
16
19
|
const promises_1 = require("node:fs/promises");
|
|
@@ -66,7 +69,6 @@ function createBrowserCodeBundleOptions(options, target, sourceFileCache) {
|
|
|
66
69
|
}
|
|
67
70
|
return buildOptions;
|
|
68
71
|
}
|
|
69
|
-
exports.createBrowserCodeBundleOptions = createBrowserCodeBundleOptions;
|
|
70
72
|
function createBrowserPolyfillBundleOptions(options, target, sourceFileCache) {
|
|
71
73
|
const namespace = 'angular:polyfills';
|
|
72
74
|
const polyfillBundleOptions = getEsBuildCommonPolyfillsOptions(options, namespace, true, sourceFileCache);
|
|
@@ -104,7 +106,6 @@ function createBrowserPolyfillBundleOptions(options, target, sourceFileCache) {
|
|
|
104
106
|
// cannot be used with fully incremental bundling yet.
|
|
105
107
|
return hasTypeScriptEntries ? buildOptions : () => buildOptions;
|
|
106
108
|
}
|
|
107
|
-
exports.createBrowserPolyfillBundleOptions = createBrowserPolyfillBundleOptions;
|
|
108
109
|
/**
|
|
109
110
|
* Create an esbuild 'build' options object for the server bundle.
|
|
110
111
|
* @param options The builder's user-provider normalized options.
|
|
@@ -185,7 +186,6 @@ function createServerCodeBundleOptions(options, target, sourceFileCache) {
|
|
|
185
186
|
}
|
|
186
187
|
return buildOptions;
|
|
187
188
|
}
|
|
188
|
-
exports.createServerCodeBundleOptions = createServerCodeBundleOptions;
|
|
189
189
|
function createServerPolyfillBundleOptions(options, target, sourceFileCache) {
|
|
190
190
|
const serverPolyfills = [];
|
|
191
191
|
const polyfillsFromConfig = new Set(options.polyfills);
|
|
@@ -230,7 +230,6 @@ function createServerPolyfillBundleOptions(options, target, sourceFileCache) {
|
|
|
230
230
|
};
|
|
231
231
|
return () => buildOptions;
|
|
232
232
|
}
|
|
233
|
-
exports.createServerPolyfillBundleOptions = createServerPolyfillBundleOptions;
|
|
234
233
|
function getEsBuildCommonOptions(options) {
|
|
235
234
|
const { workspaceRoot, outExtension, optimizationOptions, sourcemapOptions, tsconfig, externalDependencies, outputNames, preserveSymlinks, jit, loaderExtensions, jsonLogs, } = options;
|
|
236
235
|
// Ensure unique hashes for i18n translation changes when using post-process inlining.
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* found in the LICENSE file at https://angular.io/license
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.generateBudgetStats =
|
|
10
|
+
exports.generateBudgetStats = generateBudgetStats;
|
|
11
11
|
const node_path_1 = require("node:path");
|
|
12
12
|
/**
|
|
13
13
|
* Generates a bundle budget calculator compatible stats object that provides
|
|
@@ -56,4 +56,3 @@ function generateBudgetStats(metafile, initialFiles) {
|
|
|
56
56
|
}
|
|
57
57
|
return stats;
|
|
58
58
|
}
|
|
59
|
-
exports.generateBudgetStats = generateBudgetStats;
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* found in the LICENSE file at https://angular.io/license
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.checkCommonJSModules =
|
|
10
|
+
exports.checkCommonJSModules = checkCommonJSModules;
|
|
11
11
|
/**
|
|
12
12
|
* Checks the input files of a build to determine if any of the files included
|
|
13
13
|
* in the build are not ESM. ESM files can be tree-shaken and otherwise optimized
|
|
@@ -107,7 +107,6 @@ function checkCommonJSModules(metafile, allowedCommonJsDependencies) {
|
|
|
107
107
|
}
|
|
108
108
|
return messages;
|
|
109
109
|
}
|
|
110
|
-
exports.checkCommonJSModules = checkCommonJSModules;
|
|
111
110
|
/**
|
|
112
111
|
* Determines if a file path has an extension that is a JavaScript or TypeScript
|
|
113
112
|
* code file.
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* found in the LICENSE file at https://angular.io/license
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.createCompilerPluginOptions =
|
|
10
|
+
exports.createCompilerPluginOptions = createCompilerPluginOptions;
|
|
11
11
|
function createCompilerPluginOptions(options, target, sourceFileCache) {
|
|
12
12
|
const { workspaceRoot, optimizationOptions, sourcemapOptions, tsconfig, outputNames, fileReplacements, externalDependencies, preserveSymlinks, stylePreprocessorOptions, advancedOptimizations, inlineStyleLanguage, jit, cacheOptions, tailwindConfiguration, postcssConfiguration, publicPath, } = options;
|
|
13
13
|
return {
|
|
@@ -46,4 +46,3 @@ function createCompilerPluginOptions(options, target, sourceFileCache) {
|
|
|
46
46
|
},
|
|
47
47
|
};
|
|
48
48
|
}
|
|
49
|
-
exports.createCompilerPluginOptions = createCompilerPluginOptions;
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* found in the LICENSE file at https://angular.io/license
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.createExternalPackagesPlugin =
|
|
10
|
+
exports.createExternalPackagesPlugin = createExternalPackagesPlugin;
|
|
11
11
|
const node_path_1 = require("node:path");
|
|
12
12
|
const EXTERNAL_PACKAGE_RESOLUTION = Symbol('EXTERNAL_PACKAGE_RESOLUTION');
|
|
13
13
|
/**
|
|
@@ -72,4 +72,3 @@ function createExternalPackagesPlugin(options) {
|
|
|
72
72
|
},
|
|
73
73
|
};
|
|
74
74
|
}
|
|
75
|
-
exports.createExternalPackagesPlugin = createExternalPackagesPlugin;
|
|
@@ -33,7 +33,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
33
33
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
34
34
|
};
|
|
35
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
-
exports.createGlobalScriptsBundleOptions =
|
|
36
|
+
exports.createGlobalScriptsBundleOptions = createGlobalScriptsBundleOptions;
|
|
37
37
|
const magic_string_1 = __importStar(require("magic-string"));
|
|
38
38
|
const node_assert_1 = __importDefault(require("node:assert"));
|
|
39
39
|
const promises_1 = require("node:fs/promises");
|
|
@@ -139,4 +139,3 @@ function createGlobalScriptsBundleOptions(options, target, initial) {
|
|
|
139
139
|
};
|
|
140
140
|
};
|
|
141
141
|
}
|
|
142
|
-
exports.createGlobalScriptsBundleOptions = createGlobalScriptsBundleOptions;
|
|
@@ -10,7 +10,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.createGlobalStylesBundleOptions =
|
|
13
|
+
exports.createGlobalStylesBundleOptions = createGlobalStylesBundleOptions;
|
|
14
14
|
const node_assert_1 = __importDefault(require("node:assert"));
|
|
15
15
|
const bundle_options_1 = require("./stylesheets/bundle-options");
|
|
16
16
|
const virtual_module_plugin_1 = require("./virtual-module-plugin");
|
|
@@ -71,4 +71,3 @@ function createGlobalStylesBundleOptions(options, target, initial) {
|
|
|
71
71
|
return buildOptions;
|
|
72
72
|
};
|
|
73
73
|
}
|
|
74
|
-
exports.createGlobalStylesBundleOptions = createGlobalStylesBundleOptions;
|
|
@@ -10,6 +10,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.default = inlineLocale;
|
|
13
14
|
const remapping_1 = __importDefault(require("@ampproject/remapping"));
|
|
14
15
|
const core_1 = require("@babel/core");
|
|
15
16
|
const node_assert_1 = __importDefault(require("node:assert"));
|
|
@@ -39,7 +40,6 @@ async function inlineLocale(request) {
|
|
|
39
40
|
messages: result.diagnostics.messages,
|
|
40
41
|
};
|
|
41
42
|
}
|
|
42
|
-
exports.default = inlineLocale;
|
|
43
43
|
/**
|
|
44
44
|
* Cached instance of the `@angular/localize/tools` module.
|
|
45
45
|
* This is used to remove the need to repeatedly import the module per file translation.
|
|
@@ -7,7 +7,8 @@
|
|
|
7
7
|
* found in the LICENSE file at https://angular.io/license
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.
|
|
10
|
+
exports.LOCALE_DATA_BASE_MODULE = exports.LOCALE_DATA_NAMESPACE = void 0;
|
|
11
|
+
exports.createAngularLocaleDataPlugin = createAngularLocaleDataPlugin;
|
|
11
12
|
/**
|
|
12
13
|
* The internal namespace used by generated locale import statements and Angular locale data plugin.
|
|
13
14
|
*/
|
|
@@ -117,4 +118,3 @@ function createAngularLocaleDataPlugin() {
|
|
|
117
118
|
},
|
|
118
119
|
};
|
|
119
120
|
}
|
|
120
|
-
exports.createAngularLocaleDataPlugin = createAngularLocaleDataPlugin;
|
|
@@ -10,7 +10,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.generateIndexHtml =
|
|
13
|
+
exports.generateIndexHtml = generateIndexHtml;
|
|
14
14
|
const node_assert_1 = __importDefault(require("node:assert"));
|
|
15
15
|
const node_path_1 = __importDefault(require("node:path"));
|
|
16
16
|
const index_html_generator_1 = require("../../utils/index-file/index-html-generator");
|
|
@@ -89,4 +89,3 @@ async function generateIndexHtml(initialFiles, outputFiles, buildOptions, lang)
|
|
|
89
89
|
hints,
|
|
90
90
|
});
|
|
91
91
|
}
|
|
92
|
-
exports.generateIndexHtml = generateIndexHtml;
|
|
@@ -33,6 +33,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
33
33
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
34
34
|
};
|
|
35
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.default = transformJavaScript;
|
|
36
37
|
const core_1 = require("@babel/core");
|
|
37
38
|
const node_fs_1 = __importDefault(require("node:fs"));
|
|
38
39
|
const node_path_1 = __importDefault(require("node:path"));
|
|
@@ -47,7 +48,6 @@ async function transformJavaScript(request) {
|
|
|
47
48
|
// Transfer the data via `move` instead of cloning
|
|
48
49
|
return piscina_1.default.move(textEncoder.encode(transformedData));
|
|
49
50
|
}
|
|
50
|
-
exports.default = transformJavaScript;
|
|
51
51
|
/**
|
|
52
52
|
* Cached instance of the compiler-cli linker's createEs2015LinkerPlugin function.
|
|
53
53
|
*/
|
|
@@ -26,7 +26,7 @@ export declare class JavaScriptTransformer {
|
|
|
26
26
|
#private;
|
|
27
27
|
readonly maxThreads: number;
|
|
28
28
|
private readonly cache?;
|
|
29
|
-
constructor(options: JavaScriptTransformerOptions, maxThreads: number, cache?: Cache<Uint8Array
|
|
29
|
+
constructor(options: JavaScriptTransformerOptions, maxThreads: number, cache?: Cache<Uint8Array> | undefined);
|
|
30
30
|
/**
|
|
31
31
|
* Performs JavaScript transformations on a file from the filesystem.
|
|
32
32
|
* If no transformations are required, the data for the original file will be returned.
|