@angular/compiler-cli 20.0.6 → 20.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/bundles/{chunk-TPEB2IXF.js → chunk-3AHGFMNS.js} +7 -7
- package/bundles/{chunk-RYBZ5OMY.js → chunk-CY4WXRF2.js} +5 -5
- package/bundles/{chunk-LMRFLQ2K.js → chunk-CZ5FD3CS.js} +6 -17
- package/bundles/{chunk-LMRFLQ2K.js.map → chunk-CZ5FD3CS.js.map} +1 -1
- package/bundles/{chunk-7FGS2TFN.js → chunk-FPJJEIPU.js} +11 -11
- package/bundles/{chunk-SEKYV57I.js → chunk-H5Y7P5GQ.js} +3 -3
- package/bundles/{chunk-LYJARAHL.js → chunk-N3B6BMGR.js} +31 -31
- package/bundles/{chunk-PML5JK7B.js → chunk-NVYT6OPE.js} +7 -7
- package/bundles/{chunk-ZWSVOOGU.js → chunk-OOYRM3V7.js} +237 -385
- package/bundles/chunk-OOYRM3V7.js.map +6 -0
- package/bundles/{chunk-M7MXAQMK.js → chunk-OVACIG5Q.js} +3 -3
- package/bundles/{chunk-3NKMA2JO.js → chunk-U5SKOFKE.js} +2 -2
- package/bundles/{chunk-SILQIVD4.js → chunk-UMD7AW7S.js} +1689 -1077
- package/bundles/chunk-UMD7AW7S.js.map +6 -0
- package/bundles/index.js +12 -12
- package/bundles/linker/babel/index.js +12 -12
- package/bundles/linker/index.js +3 -3
- package/bundles/private/localize.js +4 -4
- package/bundles/private/migrations.js +4 -4
- package/bundles/private/tooling.js +6 -6
- package/bundles/src/bin/ng_xi18n.js +10 -10
- package/bundles/src/bin/ngc.js +8 -8
- package/linker/src/file_linker/partial_linkers/util.d.ts +1 -1
- package/package.json +3 -3
- package/src/ngtsc/annotations/component/src/handler.d.ts +5 -2
- package/src/ngtsc/annotations/component/src/metadata.d.ts +7 -0
- package/src/ngtsc/annotations/component/src/selectorless.d.ts +16 -0
- package/src/ngtsc/annotations/directive/src/handler.d.ts +2 -1
- package/src/ngtsc/annotations/directive/src/shared.d.ts +2 -2
- package/src/ngtsc/annotations/ng_module/src/handler.d.ts +2 -1
- package/src/ngtsc/annotations/src/pipe.d.ts +1 -1
- package/src/ngtsc/core/api/src/public_options.d.ts +13 -0
- package/src/ngtsc/core/src/compiler.d.ts +1 -0
- package/src/ngtsc/diagnostics/src/error_code.d.ts +4 -0
- package/src/ngtsc/docs/src/entities.d.ts +1 -1
- package/src/ngtsc/indexer/src/api.d.ts +20 -8
- package/src/ngtsc/metadata/src/api.d.ts +9 -3
- package/src/ngtsc/scope/index.d.ts +2 -1
- package/src/ngtsc/scope/src/api.d.ts +12 -2
- package/src/ngtsc/scope/src/selectorless_scope.d.ts +25 -0
- package/src/ngtsc/scope/src/typecheck.d.ts +5 -3
- package/src/ngtsc/transform/index.d.ts +1 -0
- package/src/ngtsc/transform/src/api.d.ts +0 -2
- package/src/ngtsc/transform/src/compilation.d.ts +2 -1
- package/src/ngtsc/transform/src/implicit_signal_debug_name_transform.d.ts +74 -0
- package/src/ngtsc/transform/src/transform.d.ts +1 -1
- package/src/ngtsc/translator/src/translator.d.ts +0 -3
- package/src/ngtsc/typecheck/api/api.d.ts +3 -0
- package/src/ngtsc/typecheck/api/checker.d.ts +24 -6
- package/src/ngtsc/typecheck/api/scope.d.ts +17 -1
- package/src/ngtsc/typecheck/api/symbols.d.ts +39 -3
- package/src/ngtsc/typecheck/src/checker.d.ts +12 -4
- package/src/ngtsc/typecheck/src/completion.d.ts +7 -2
- package/src/ngtsc/typecheck/src/oob.d.ts +7 -10
- package/src/ngtsc/typecheck/src/template_symbol_builder.d.ts +6 -2
- package/bundles/chunk-SILQIVD4.js.map +0 -6
- package/bundles/chunk-ZWSVOOGU.js.map +0 -6
- /package/bundles/{chunk-TPEB2IXF.js.map → chunk-3AHGFMNS.js.map} +0 -0
- /package/bundles/{chunk-RYBZ5OMY.js.map → chunk-CY4WXRF2.js.map} +0 -0
- /package/bundles/{chunk-7FGS2TFN.js.map → chunk-FPJJEIPU.js.map} +0 -0
- /package/bundles/{chunk-SEKYV57I.js.map → chunk-H5Y7P5GQ.js.map} +0 -0
- /package/bundles/{chunk-LYJARAHL.js.map → chunk-N3B6BMGR.js.map} +0 -0
- /package/bundles/{chunk-PML5JK7B.js.map → chunk-NVYT6OPE.js.map} +0 -0
- /package/bundles/{chunk-M7MXAQMK.js.map → chunk-OVACIG5Q.js.map} +0 -0
- /package/bundles/{chunk-3NKMA2JO.js.map → chunk-U5SKOFKE.js.map} +0 -0
package/bundles/index.js
CHANGED
|
@@ -28,21 +28,21 @@ import {
|
|
|
28
28
|
isTsDiagnostic,
|
|
29
29
|
performCompilation,
|
|
30
30
|
readConfiguration
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-OOYRM3V7.js";
|
|
32
32
|
import {
|
|
33
33
|
ConsoleLogger,
|
|
34
34
|
LogLevel
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-H5Y7P5GQ.js";
|
|
36
36
|
import {
|
|
37
37
|
GLOBAL_DEFS_FOR_TERSER,
|
|
38
38
|
GLOBAL_DEFS_FOR_TERSER_WITH_AOT,
|
|
39
39
|
constructorParametersDownlevelTransform
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-OVACIG5Q.js";
|
|
41
41
|
import {
|
|
42
42
|
angularJitApplicationTransform,
|
|
43
43
|
getDownlevelDecoratorsTransform,
|
|
44
44
|
getInitializerApiJitTransform
|
|
45
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-FPJJEIPU.js";
|
|
46
46
|
import {
|
|
47
47
|
ActivePerfRecorder,
|
|
48
48
|
ErrorCode,
|
|
@@ -51,8 +51,8 @@ import {
|
|
|
51
51
|
TsCreateProgramDriver,
|
|
52
52
|
isLocalCompilationDiagnostics,
|
|
53
53
|
ngErrorCode
|
|
54
|
-
} from "./chunk-
|
|
55
|
-
import "./chunk-
|
|
54
|
+
} from "./chunk-UMD7AW7S.js";
|
|
55
|
+
import "./chunk-CZ5FD3CS.js";
|
|
56
56
|
import {
|
|
57
57
|
InvalidFileSystem,
|
|
58
58
|
LogicalFileSystem,
|
|
@@ -74,17 +74,17 @@ import {
|
|
|
74
74
|
resolve,
|
|
75
75
|
setFileSystem,
|
|
76
76
|
toRelativeImport
|
|
77
|
-
} from "./chunk-
|
|
77
|
+
} from "./chunk-3AHGFMNS.js";
|
|
78
78
|
import {
|
|
79
79
|
NodeJSFileSystem
|
|
80
|
-
} from "./chunk-
|
|
80
|
+
} from "./chunk-U5SKOFKE.js";
|
|
81
81
|
import "./chunk-KPQ72R34.js";
|
|
82
82
|
|
|
83
|
-
// bazel-out/
|
|
83
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/version.js
|
|
84
84
|
import { Version } from "@angular/compiler";
|
|
85
|
-
var VERSION = new Version("20.0.
|
|
85
|
+
var VERSION = new Version("20.1.0-next.1");
|
|
86
86
|
|
|
87
|
-
// bazel-out/
|
|
87
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/tsc_plugin.js
|
|
88
88
|
var NgTscPlugin = class {
|
|
89
89
|
ngOptions;
|
|
90
90
|
name = "ngtsc";
|
|
@@ -160,7 +160,7 @@ var NgTscPlugin = class {
|
|
|
160
160
|
}
|
|
161
161
|
};
|
|
162
162
|
|
|
163
|
-
// bazel-out/
|
|
163
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/index.js
|
|
164
164
|
setFileSystem(new NodeJSFileSystem());
|
|
165
165
|
export {
|
|
166
166
|
ConsoleLogger,
|
|
@@ -8,22 +8,22 @@ import {
|
|
|
8
8
|
LinkerEnvironment,
|
|
9
9
|
assert,
|
|
10
10
|
isFatalLinkerError
|
|
11
|
-
} from "../../chunk-
|
|
11
|
+
} from "../../chunk-N3B6BMGR.js";
|
|
12
12
|
import {
|
|
13
13
|
ConsoleLogger,
|
|
14
14
|
LogLevel
|
|
15
|
-
} from "../../chunk-
|
|
16
|
-
import "../../chunk-
|
|
17
|
-
import "../../chunk-
|
|
15
|
+
} from "../../chunk-H5Y7P5GQ.js";
|
|
16
|
+
import "../../chunk-NVYT6OPE.js";
|
|
17
|
+
import "../../chunk-CZ5FD3CS.js";
|
|
18
18
|
import {
|
|
19
19
|
NodeJSFileSystem
|
|
20
|
-
} from "../../chunk-
|
|
20
|
+
} from "../../chunk-U5SKOFKE.js";
|
|
21
21
|
import "../../chunk-KPQ72R34.js";
|
|
22
22
|
|
|
23
|
-
// bazel-out/
|
|
23
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/linker/babel/src/es2015_linker_plugin.js
|
|
24
24
|
import { types as t4 } from "@babel/core";
|
|
25
25
|
|
|
26
|
-
// bazel-out/
|
|
26
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/linker/babel/src/ast/babel_ast_factory.js
|
|
27
27
|
import { types as t } from "@babel/core";
|
|
28
28
|
var BabelAstFactory = class {
|
|
29
29
|
sourceUrl;
|
|
@@ -155,7 +155,7 @@ function isLExpression(expr) {
|
|
|
155
155
|
return t.isLVal(expr);
|
|
156
156
|
}
|
|
157
157
|
|
|
158
|
-
// bazel-out/
|
|
158
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/linker/babel/src/ast/babel_ast_host.js
|
|
159
159
|
import { types as t2 } from "@babel/core";
|
|
160
160
|
var BabelAstHost = class {
|
|
161
161
|
getSymbolName(node) {
|
|
@@ -281,7 +281,7 @@ function isMinifiedBooleanLiteral(node) {
|
|
|
281
281
|
return t2.isUnaryExpression(node) && node.prefix && node.operator === "!" && t2.isNumericLiteral(node.argument) && (node.argument.value === 0 || node.argument.value === 1);
|
|
282
282
|
}
|
|
283
283
|
|
|
284
|
-
// bazel-out/
|
|
284
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/linker/babel/src/babel_declaration_scope.js
|
|
285
285
|
import { types as t3 } from "@babel/core";
|
|
286
286
|
var BabelDeclarationScope = class {
|
|
287
287
|
declarationScope;
|
|
@@ -308,7 +308,7 @@ var BabelDeclarationScope = class {
|
|
|
308
308
|
}
|
|
309
309
|
};
|
|
310
310
|
|
|
311
|
-
// bazel-out/
|
|
311
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/linker/babel/src/es2015_linker_plugin.js
|
|
312
312
|
function createEs2015LinkerPlugin({ fileSystem, logger, ...options }) {
|
|
313
313
|
let fileLinker = null;
|
|
314
314
|
return {
|
|
@@ -408,7 +408,7 @@ function buildCodeFrameError(file, message, node) {
|
|
|
408
408
|
return `${filename}: ${error.message}`;
|
|
409
409
|
}
|
|
410
410
|
|
|
411
|
-
// bazel-out/
|
|
411
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/linker/babel/src/babel_plugin.js
|
|
412
412
|
function defaultLinkerPlugin(api, options) {
|
|
413
413
|
api.assertVersion(7);
|
|
414
414
|
return createEs2015LinkerPlugin({
|
|
@@ -418,7 +418,7 @@ function defaultLinkerPlugin(api, options) {
|
|
|
418
418
|
});
|
|
419
419
|
}
|
|
420
420
|
|
|
421
|
-
// bazel-out/
|
|
421
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/linker/babel/index.js
|
|
422
422
|
var babel_default = defaultLinkerPlugin;
|
|
423
423
|
export {
|
|
424
424
|
createEs2015LinkerPlugin,
|
package/bundles/linker/index.js
CHANGED
|
@@ -10,9 +10,9 @@ import {
|
|
|
10
10
|
assert,
|
|
11
11
|
isFatalLinkerError,
|
|
12
12
|
needsLinking
|
|
13
|
-
} from "../chunk-
|
|
14
|
-
import "../chunk-
|
|
15
|
-
import "../chunk-
|
|
13
|
+
} from "../chunk-N3B6BMGR.js";
|
|
14
|
+
import "../chunk-NVYT6OPE.js";
|
|
15
|
+
import "../chunk-CZ5FD3CS.js";
|
|
16
16
|
import "../chunk-KPQ72R34.js";
|
|
17
17
|
export {
|
|
18
18
|
DEFAULT_LINKER_OPTIONS,
|
|
@@ -5,11 +5,11 @@
|
|
|
5
5
|
import {
|
|
6
6
|
ConsoleLogger,
|
|
7
7
|
LogLevel
|
|
8
|
-
} from "../chunk-
|
|
8
|
+
} from "../chunk-H5Y7P5GQ.js";
|
|
9
9
|
import {
|
|
10
10
|
SourceFile,
|
|
11
11
|
SourceFileLoader
|
|
12
|
-
} from "../chunk-
|
|
12
|
+
} from "../chunk-NVYT6OPE.js";
|
|
13
13
|
import {
|
|
14
14
|
InvalidFileSystem,
|
|
15
15
|
LogicalFileSystem,
|
|
@@ -31,10 +31,10 @@ import {
|
|
|
31
31
|
resolve,
|
|
32
32
|
setFileSystem,
|
|
33
33
|
toRelativeImport
|
|
34
|
-
} from "../chunk-
|
|
34
|
+
} from "../chunk-3AHGFMNS.js";
|
|
35
35
|
import {
|
|
36
36
|
NodeJSFileSystem
|
|
37
|
-
} from "../chunk-
|
|
37
|
+
} from "../chunk-U5SKOFKE.js";
|
|
38
38
|
import "../chunk-KPQ72R34.js";
|
|
39
39
|
export {
|
|
40
40
|
ConsoleLogger,
|
|
@@ -13,10 +13,10 @@ import {
|
|
|
13
13
|
TypeScriptReflectionHost,
|
|
14
14
|
createForwardRefResolver,
|
|
15
15
|
reflectObjectLiteral
|
|
16
|
-
} from "../chunk-
|
|
17
|
-
import "../chunk-
|
|
18
|
-
import "../chunk-
|
|
19
|
-
import "../chunk-
|
|
16
|
+
} from "../chunk-UMD7AW7S.js";
|
|
17
|
+
import "../chunk-CZ5FD3CS.js";
|
|
18
|
+
import "../chunk-3AHGFMNS.js";
|
|
19
|
+
import "../chunk-U5SKOFKE.js";
|
|
20
20
|
import "../chunk-KPQ72R34.js";
|
|
21
21
|
export {
|
|
22
22
|
DynamicValue,
|
|
@@ -6,12 +6,12 @@ import {
|
|
|
6
6
|
GLOBAL_DEFS_FOR_TERSER,
|
|
7
7
|
GLOBAL_DEFS_FOR_TERSER_WITH_AOT,
|
|
8
8
|
constructorParametersDownlevelTransform
|
|
9
|
-
} from "../chunk-
|
|
10
|
-
import "../chunk-
|
|
11
|
-
import "../chunk-
|
|
12
|
-
import "../chunk-
|
|
13
|
-
import "../chunk-
|
|
14
|
-
import "../chunk-
|
|
9
|
+
} from "../chunk-OVACIG5Q.js";
|
|
10
|
+
import "../chunk-FPJJEIPU.js";
|
|
11
|
+
import "../chunk-UMD7AW7S.js";
|
|
12
|
+
import "../chunk-CZ5FD3CS.js";
|
|
13
|
+
import "../chunk-3AHGFMNS.js";
|
|
14
|
+
import "../chunk-U5SKOFKE.js";
|
|
15
15
|
import "../chunk-KPQ72R34.js";
|
|
16
16
|
export {
|
|
17
17
|
GLOBAL_DEFS_FOR_TERSER,
|
|
@@ -6,25 +6,25 @@
|
|
|
6
6
|
import {
|
|
7
7
|
main,
|
|
8
8
|
readCommandLineAndConfiguration
|
|
9
|
-
} from "../../chunk-
|
|
9
|
+
} from "../../chunk-CY4WXRF2.js";
|
|
10
10
|
import {
|
|
11
11
|
EmitFlags
|
|
12
|
-
} from "../../chunk-
|
|
13
|
-
import "../../chunk-
|
|
14
|
-
import "../../chunk-
|
|
15
|
-
import "../../chunk-
|
|
12
|
+
} from "../../chunk-OOYRM3V7.js";
|
|
13
|
+
import "../../chunk-FPJJEIPU.js";
|
|
14
|
+
import "../../chunk-UMD7AW7S.js";
|
|
15
|
+
import "../../chunk-CZ5FD3CS.js";
|
|
16
16
|
import {
|
|
17
17
|
setFileSystem
|
|
18
|
-
} from "../../chunk-
|
|
18
|
+
} from "../../chunk-3AHGFMNS.js";
|
|
19
19
|
import {
|
|
20
20
|
NodeJSFileSystem
|
|
21
|
-
} from "../../chunk-
|
|
21
|
+
} from "../../chunk-U5SKOFKE.js";
|
|
22
22
|
import "../../chunk-KPQ72R34.js";
|
|
23
23
|
|
|
24
|
-
// bazel-out/
|
|
24
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/bin/ng_xi18n.js
|
|
25
25
|
import "reflect-metadata";
|
|
26
26
|
|
|
27
|
-
// bazel-out/
|
|
27
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/extract_i18n.js
|
|
28
28
|
import yargs from "yargs";
|
|
29
29
|
function mainXi18n(args2, consoleError = console.error) {
|
|
30
30
|
const config = readXi18nCommandLineAndConfiguration(args2);
|
|
@@ -47,7 +47,7 @@ function readXi18nCommandLineAndConfiguration(args2) {
|
|
|
47
47
|
return { ...config, emitFlags: EmitFlags.I18nBundle };
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
-
// bazel-out/
|
|
50
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/bin/ng_xi18n.js
|
|
51
51
|
process.title = "Angular i18n Message Extractor (ng-xi18n)";
|
|
52
52
|
var args = process.argv.slice(2);
|
|
53
53
|
setFileSystem(new NodeJSFileSystem());
|
package/bundles/src/bin/ngc.js
CHANGED
|
@@ -5,20 +5,20 @@
|
|
|
5
5
|
|
|
6
6
|
import {
|
|
7
7
|
main
|
|
8
|
-
} from "../../chunk-
|
|
9
|
-
import "../../chunk-
|
|
10
|
-
import "../../chunk-
|
|
11
|
-
import "../../chunk-
|
|
12
|
-
import "../../chunk-
|
|
8
|
+
} from "../../chunk-CY4WXRF2.js";
|
|
9
|
+
import "../../chunk-OOYRM3V7.js";
|
|
10
|
+
import "../../chunk-FPJJEIPU.js";
|
|
11
|
+
import "../../chunk-UMD7AW7S.js";
|
|
12
|
+
import "../../chunk-CZ5FD3CS.js";
|
|
13
13
|
import {
|
|
14
14
|
setFileSystem
|
|
15
|
-
} from "../../chunk-
|
|
15
|
+
} from "../../chunk-3AHGFMNS.js";
|
|
16
16
|
import {
|
|
17
17
|
NodeJSFileSystem
|
|
18
|
-
} from "../../chunk-
|
|
18
|
+
} from "../../chunk-U5SKOFKE.js";
|
|
19
19
|
import "../../chunk-KPQ72R34.js";
|
|
20
20
|
|
|
21
|
-
// bazel-out/
|
|
21
|
+
// bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/bin/ngc.js
|
|
22
22
|
import "reflect-metadata";
|
|
23
23
|
async function runNgcComamnd() {
|
|
24
24
|
process.title = "Angular Compiler (ngc)";
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
import { MaybeForwardRefExpression, outputAst as o, R3DeclareDependencyMetadata, R3DependencyMetadata, R3Reference } from '@angular/compiler';
|
|
9
9
|
import { AstObject, AstValue } from '../../ast/ast_value';
|
|
10
|
-
export declare const PLACEHOLDER_VERSION = "20.0.
|
|
10
|
+
export declare const PLACEHOLDER_VERSION = "20.1.0-next.1";
|
|
11
11
|
export declare function wrapReference<TExpression>(wrapped: o.WrappedNodeExpr<TExpression>): R3Reference;
|
|
12
12
|
/**
|
|
13
13
|
* Parses the value of an enum from the AST value's symbol name.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@angular/compiler-cli",
|
|
3
|
-
"version": "20.0.
|
|
3
|
+
"version": "20.1.0-next.1",
|
|
4
4
|
"description": "Angular - the compiler CLI for Node.js",
|
|
5
5
|
"typings": "index.d.ts",
|
|
6
6
|
"bin": {
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
}
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
|
-
"@babel/core": "7.27.
|
|
41
|
+
"@babel/core": "7.27.4",
|
|
42
42
|
"@jridgewell/sourcemap-codec": "^1.4.14",
|
|
43
43
|
"reflect-metadata": "^0.2.0",
|
|
44
44
|
"chokidar": "^4.0.0",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"yargs": "^18.0.0"
|
|
49
49
|
},
|
|
50
50
|
"peerDependencies": {
|
|
51
|
-
"@angular/compiler": "20.0.
|
|
51
|
+
"@angular/compiler": "20.1.0-next.1",
|
|
52
52
|
"typescript": ">=5.8 <5.9"
|
|
53
53
|
},
|
|
54
54
|
"peerDependenciesMeta": {
|
|
@@ -75,7 +75,8 @@ export declare class ComponentDecoratorHandler implements DecoratorHandler<Decor
|
|
|
75
75
|
private readonly implicitStandaloneValue;
|
|
76
76
|
private readonly typeCheckHostBindings;
|
|
77
77
|
private readonly enableSelectorless;
|
|
78
|
-
|
|
78
|
+
private readonly emitDeclarationOnly;
|
|
79
|
+
constructor(reflector: ReflectionHost, evaluator: PartialEvaluator, metaRegistry: MetadataRegistry, metaReader: MetadataReader, scopeReader: ComponentScopeReader, compilerHost: Pick<ts.CompilerHost, 'getCanonicalFileName'>, scopeRegistry: LocalModuleScopeRegistry, typeCheckScopeRegistry: TypeCheckScopeRegistry, resourceRegistry: ResourceRegistry, isCore: boolean, strictCtorDeps: boolean, resourceLoader: ResourceLoader, rootDirs: ReadonlyArray<string>, defaultPreserveWhitespaces: boolean, i18nUseExternalIds: boolean, enableI18nLegacyMessageIdFormat: boolean, usePoisonedData: boolean, i18nNormalizeLineEndingsInICUs: boolean, moduleResolver: ModuleResolver, cycleAnalyzer: CycleAnalyzer, cycleHandlingStrategy: CycleHandlingStrategy, refEmitter: ReferenceEmitter, referencesRegistry: ReferencesRegistry, depTracker: DependencyTracker | null, injectableRegistry: InjectableClassRegistry, semanticDepGraphUpdater: SemanticDepGraphUpdater | null, annotateForClosureCompiler: boolean, perf: PerfRecorder, hostDirectivesResolver: HostDirectivesResolver, importTracker: ImportedSymbolsTracker, includeClassMetadata: boolean, compilationMode: CompilationMode, deferredSymbolTracker: DeferredSymbolTracker, forbidOrphanRendering: boolean, enableBlockSyntax: boolean, enableLetSyntax: boolean, externalRuntimeStyles: boolean, localCompilationExtraImportsTracker: LocalCompilationExtraImportsTracker | null, jitDeclarationRegistry: JitDeclarationRegistry, i18nPreserveSignificantWhitespace: boolean, strictStandalone: boolean, enableHmr: boolean, implicitStandaloneValue: boolean, typeCheckHostBindings: boolean, enableSelectorless: boolean, emitDeclarationOnly: boolean);
|
|
79
80
|
private literalCache;
|
|
80
81
|
private elementSchemaRegistry;
|
|
81
82
|
/**
|
|
@@ -152,6 +153,8 @@ export declare class ComponentDecoratorHandler implements DecoratorHandler<Decor
|
|
|
152
153
|
* `@Component.deferredImports`) and registers imported types as deferrable
|
|
153
154
|
* candidates.
|
|
154
155
|
*/
|
|
155
|
-
private
|
|
156
|
+
private registerDeferrableCandidate;
|
|
156
157
|
private compileDeferBlocks;
|
|
158
|
+
/** Creates a new binding parser. */
|
|
159
|
+
private getNewBindingParser;
|
|
157
160
|
}
|
|
@@ -71,6 +71,13 @@ export interface ComponentAnalysisData {
|
|
|
71
71
|
rawHostDirectives: ts.Expression | null;
|
|
72
72
|
/** Raw nodes representing the host bindings of the directive. */
|
|
73
73
|
hostBindingNodes: HostBindingNodes;
|
|
74
|
+
/** Whether selectorless is enabled for the specific component. */
|
|
75
|
+
selectorlessEnabled: boolean;
|
|
76
|
+
/**
|
|
77
|
+
* Names of the symbols within the source file that are referenced directly inside the template.
|
|
78
|
+
* Used to reduce the amount of lookups when determining which dependencies to expose.
|
|
79
|
+
*/
|
|
80
|
+
localReferencedSymbols: Set<string> | null;
|
|
74
81
|
}
|
|
75
82
|
export interface ComponentResolutionData {
|
|
76
83
|
declarations: R3TemplateDependencyMetadata[];
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright Google LLC All Rights Reserved.
|
|
4
|
+
*
|
|
5
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
+
* found in the LICENSE file at https://angular.dev/license
|
|
7
|
+
*/
|
|
8
|
+
import { TmplAstNode } from '@angular/compiler';
|
|
9
|
+
/**
|
|
10
|
+
* Analyzes a component's template to determine if it's using selectorless syntax
|
|
11
|
+
* and to extract the names of the selectorless symbols that are referenced.
|
|
12
|
+
*/
|
|
13
|
+
export declare function analyzeTemplateForSelectorless(template: TmplAstNode[]): {
|
|
14
|
+
isSelectorless: boolean;
|
|
15
|
+
localReferencedSymbols: Set<string> | null;
|
|
16
|
+
};
|
|
@@ -61,7 +61,8 @@ export declare class DirectiveDecoratorHandler implements DecoratorHandler<Decor
|
|
|
61
61
|
private readonly implicitStandaloneValue;
|
|
62
62
|
private readonly usePoisonedData;
|
|
63
63
|
private readonly typeCheckHostBindings;
|
|
64
|
-
|
|
64
|
+
private readonly emitDeclarationOnly;
|
|
65
|
+
constructor(reflector: ReflectionHost, evaluator: PartialEvaluator, metaRegistry: MetadataRegistry, scopeRegistry: LocalModuleScopeRegistry, metaReader: MetadataReader, injectableRegistry: InjectableClassRegistry, refEmitter: ReferenceEmitter, referencesRegistry: ReferencesRegistry, isCore: boolean, strictCtorDeps: boolean, semanticDepGraphUpdater: SemanticDepGraphUpdater | null, annotateForClosureCompiler: boolean, perf: PerfRecorder, importTracker: ImportedSymbolsTracker, includeClassMetadata: boolean, typeCheckScopeRegistry: TypeCheckScopeRegistry, compilationMode: CompilationMode, jitDeclarationRegistry: JitDeclarationRegistry, resourceRegistry: ResourceRegistry, strictStandalone: boolean, implicitStandaloneValue: boolean, usePoisonedData: boolean, typeCheckHostBindings: boolean, emitDeclarationOnly: boolean);
|
|
65
66
|
readonly precedence = HandlerPrecedence.PRIMARY;
|
|
66
67
|
readonly name = "DirectiveDecoratorHandler";
|
|
67
68
|
detect(node: ClassDeclaration, decorators: Decorator[] | null): DetectResult<Decorator | null> | undefined;
|
|
@@ -26,7 +26,7 @@ export interface HostBindingNodes {
|
|
|
26
26
|
* appear in the declarations of an `NgModule` and additional verification is done when processing
|
|
27
27
|
* the module.
|
|
28
28
|
*/
|
|
29
|
-
export declare function extractDirectiveMetadata(clazz: ClassDeclaration, decorator: Readonly<Decorator>, reflector: ReflectionHost, importTracker: ImportedSymbolsTracker, evaluator: PartialEvaluator, refEmitter: ReferenceEmitter, referencesRegistry: ReferencesRegistry, isCore: boolean, annotateForClosureCompiler: boolean, compilationMode: CompilationMode, defaultSelector: string | null, strictStandalone: boolean, implicitStandaloneValue: boolean): {
|
|
29
|
+
export declare function extractDirectiveMetadata(clazz: ClassDeclaration, decorator: Readonly<Decorator>, reflector: ReflectionHost, importTracker: ImportedSymbolsTracker, evaluator: PartialEvaluator, refEmitter: ReferenceEmitter, referencesRegistry: ReferencesRegistry, isCore: boolean, annotateForClosureCompiler: boolean, compilationMode: CompilationMode, defaultSelector: string | null, strictStandalone: boolean, implicitStandaloneValue: boolean, emitDeclarationOnly: boolean): {
|
|
30
30
|
jitForced: false;
|
|
31
31
|
decorator: Map<string, ts.Expression>;
|
|
32
32
|
metadata: R3DirectiveMetadata;
|
|
@@ -54,6 +54,6 @@ export declare function parseFieldStringArrayValue(directive: Map<string, ts.Exp
|
|
|
54
54
|
* automatically captured in the type of the `InputSignal`.
|
|
55
55
|
*
|
|
56
56
|
*/
|
|
57
|
-
export declare function parseDecoratorInputTransformFunction(clazz: ClassDeclaration, classPropertyName: string, value: DynamicValue | Reference, reflector: ReflectionHost, refEmitter: ReferenceEmitter, compilationMode: CompilationMode): DecoratorInputTransform;
|
|
57
|
+
export declare function parseDecoratorInputTransformFunction(clazz: ClassDeclaration, classPropertyName: string, value: DynamicValue | Reference, reflector: ReflectionHost, refEmitter: ReferenceEmitter, compilationMode: CompilationMode, emitDeclarationOnly: boolean): DecoratorInputTransform;
|
|
58
58
|
export declare function extractHostBindingResources(nodes: HostBindingNodes): ReadonlySet<Resource>;
|
|
59
59
|
export {};
|
|
@@ -85,7 +85,8 @@ export declare class NgModuleDecoratorHandler implements DecoratorHandler<Decora
|
|
|
85
85
|
private readonly compilationMode;
|
|
86
86
|
private readonly localCompilationExtraImportsTracker;
|
|
87
87
|
private readonly jitDeclarationRegistry;
|
|
88
|
-
|
|
88
|
+
private readonly emitDeclarationOnly;
|
|
89
|
+
constructor(reflector: ReflectionHost, evaluator: PartialEvaluator, metaReader: MetadataReader, metaRegistry: MetadataRegistry, scopeRegistry: LocalModuleScopeRegistry, referencesRegistry: ReferencesRegistry, exportedProviderStatusResolver: ExportedProviderStatusResolver, semanticDepGraphUpdater: SemanticDepGraphUpdater | null, isCore: boolean, refEmitter: ReferenceEmitter, annotateForClosureCompiler: boolean, onlyPublishPublicTypings: boolean, injectableRegistry: InjectableClassRegistry, perf: PerfRecorder, includeClassMetadata: boolean, includeSelectorScope: boolean, compilationMode: CompilationMode, localCompilationExtraImportsTracker: LocalCompilationExtraImportsTracker | null, jitDeclarationRegistry: JitDeclarationRegistry, emitDeclarationOnly: boolean);
|
|
89
90
|
readonly precedence = HandlerPrecedence.PRIMARY;
|
|
90
91
|
readonly name = "NgModuleDecoratorHandler";
|
|
91
92
|
detect(node: ClassDeclaration, decorators: Decorator[] | null): DetectResult<Decorator> | undefined;
|
|
@@ -18,7 +18,7 @@ import { InjectableClassRegistry } from '../common';
|
|
|
18
18
|
export interface PipeHandlerData {
|
|
19
19
|
meta: R3PipeMetadata;
|
|
20
20
|
classMetadata: R3ClassMetadata | null;
|
|
21
|
-
pipeNameExpr: ts.Expression;
|
|
21
|
+
pipeNameExpr: ts.Expression | null;
|
|
22
22
|
decorator: ts.Decorator | null;
|
|
23
23
|
}
|
|
24
24
|
/**
|
|
@@ -314,6 +314,19 @@ export interface BazelAndG3Options {
|
|
|
314
314
|
* extra imports are needed for bundling purposes in g3.
|
|
315
315
|
*/
|
|
316
316
|
generateExtraImportsInLocalMode?: boolean;
|
|
317
|
+
/**
|
|
318
|
+
* Whether to allow the experimental declaration-only emission mode when the `emitDeclarationOnly`
|
|
319
|
+
* TS compiler option is enabled.
|
|
320
|
+
*
|
|
321
|
+
* The declaration-only emission mode relies on the local compilation mode for fast type
|
|
322
|
+
* declaration emission, i.e. emitting `.d.ts` files without type-checking. Certain restrictions
|
|
323
|
+
* on supported code constructs apply due to the absence of type information for external
|
|
324
|
+
* references.
|
|
325
|
+
*
|
|
326
|
+
* The mode is experimental and specifically tailored to support fast type declaration emission
|
|
327
|
+
* for the Gemini app in g3 for the initial phase of the experiment.
|
|
328
|
+
*/
|
|
329
|
+
_experimentalAllowEmitDeclarationOnly?: boolean;
|
|
317
330
|
}
|
|
318
331
|
/**
|
|
319
332
|
* Options related to i18n compilation support.
|
|
@@ -136,6 +136,7 @@ export declare class NgCompiler {
|
|
|
136
136
|
private readonly enableHmr;
|
|
137
137
|
private readonly implicitStandaloneValue;
|
|
138
138
|
private readonly enableSelectorless;
|
|
139
|
+
private readonly emitDeclarationOnly;
|
|
139
140
|
/**
|
|
140
141
|
* `NgCompiler` can be reused for multiple compilations (for resource-only changes), and each
|
|
141
142
|
* new compilation uses a fresh `PerfRecorder`. Thus, classes created with a lifespan of the
|
|
@@ -141,6 +141,10 @@ export declare enum ErrorCode {
|
|
|
141
141
|
* class used as a component).
|
|
142
142
|
*/
|
|
143
143
|
INCORRECT_NAMED_TEMPLATE_DEPENDENCY_TYPE = 2025,
|
|
144
|
+
/**
|
|
145
|
+
* Raised for `@Component` fields that aren't supported in a selectorless context.
|
|
146
|
+
*/
|
|
147
|
+
UNSUPPORTED_SELECTORLESS_COMPONENT_FIELD = 2026,
|
|
144
148
|
SYMBOL_NOT_EXPORTED = 3001,
|
|
145
149
|
/**
|
|
146
150
|
* Raised when a relationship between directives and/or pipes would cause a cyclic import to be
|
|
@@ -114,7 +114,7 @@ export interface DirectiveEntry extends ClassEntry {
|
|
|
114
114
|
isStandalone: boolean;
|
|
115
115
|
}
|
|
116
116
|
export interface PipeEntry extends ClassEntry {
|
|
117
|
-
pipeName: string;
|
|
117
|
+
pipeName: string | null;
|
|
118
118
|
isStandalone: boolean;
|
|
119
119
|
usage: string;
|
|
120
120
|
isPure: boolean;
|
|
@@ -18,7 +18,9 @@ export declare enum IdentifierKind {
|
|
|
18
18
|
Attribute = 4,
|
|
19
19
|
Reference = 5,
|
|
20
20
|
Variable = 6,
|
|
21
|
-
LetDeclaration = 7
|
|
21
|
+
LetDeclaration = 7,
|
|
22
|
+
Component = 8,
|
|
23
|
+
Directive = 9
|
|
22
24
|
}
|
|
23
25
|
/**
|
|
24
26
|
* Describes a semantically-interesting identifier in a template, such as an interpolated variable
|
|
@@ -58,7 +60,7 @@ interface DirectiveReference {
|
|
|
58
60
|
selector: string;
|
|
59
61
|
}
|
|
60
62
|
/** A base interface for element and template identifiers. */
|
|
61
|
-
interface
|
|
63
|
+
interface BaseDirectiveHostIdentifier extends TemplateIdentifier {
|
|
62
64
|
/** Attributes on an element or template. */
|
|
63
65
|
attributes: Set<AttributeIdentifier>;
|
|
64
66
|
/** Directives applied to an element or template. */
|
|
@@ -69,20 +71,28 @@ interface BaseElementOrTemplateIdentifier extends TemplateIdentifier {
|
|
|
69
71
|
* element tag, which can be parsed by an indexer to determine where used directives should be
|
|
70
72
|
* referenced.
|
|
71
73
|
*/
|
|
72
|
-
export interface ElementIdentifier extends
|
|
74
|
+
export interface ElementIdentifier extends BaseDirectiveHostIdentifier {
|
|
73
75
|
kind: IdentifierKind.Element;
|
|
74
76
|
}
|
|
75
77
|
/** Describes an indexed template node in a component template file. */
|
|
76
|
-
export interface TemplateNodeIdentifier extends
|
|
78
|
+
export interface TemplateNodeIdentifier extends BaseDirectiveHostIdentifier {
|
|
77
79
|
kind: IdentifierKind.Template;
|
|
78
80
|
}
|
|
81
|
+
/** Describes a selectorless component node in a template file. */
|
|
82
|
+
export interface ComponentNodeIdentifier extends BaseDirectiveHostIdentifier {
|
|
83
|
+
kind: IdentifierKind.Component;
|
|
84
|
+
}
|
|
85
|
+
/** Describes a selectorless directive node in a template file. */
|
|
86
|
+
export interface DirectiveNodeIdentifier extends BaseDirectiveHostIdentifier {
|
|
87
|
+
kind: IdentifierKind.Directive;
|
|
88
|
+
}
|
|
79
89
|
/** Describes a reference in a template like "foo" in `<div #foo></div>`. */
|
|
80
90
|
export interface ReferenceIdentifier extends TemplateIdentifier {
|
|
81
91
|
kind: IdentifierKind.Reference;
|
|
82
92
|
/** The target of this reference. If the target is not known, this is `null`. */
|
|
83
93
|
target: {
|
|
84
94
|
/** The template AST node that the reference targets. */
|
|
85
|
-
node:
|
|
95
|
+
node: DirectiveHostIdentifier;
|
|
86
96
|
/**
|
|
87
97
|
* The directive on `node` that the reference targets. If no directive is targeted, this is
|
|
88
98
|
* `null`.
|
|
@@ -102,13 +112,15 @@ export interface LetDeclarationIdentifier extends TemplateIdentifier {
|
|
|
102
112
|
* Identifiers recorded at the top level of the template, without any context about the HTML nodes
|
|
103
113
|
* they were discovered in.
|
|
104
114
|
*/
|
|
105
|
-
export type TopLevelIdentifier = PropertyIdentifier | ElementIdentifier | TemplateNodeIdentifier | ReferenceIdentifier | VariableIdentifier | MethodIdentifier | LetDeclarationIdentifier;
|
|
115
|
+
export type TopLevelIdentifier = PropertyIdentifier | ElementIdentifier | TemplateNodeIdentifier | ReferenceIdentifier | VariableIdentifier | MethodIdentifier | LetDeclarationIdentifier | ComponentNodeIdentifier | DirectiveNodeIdentifier;
|
|
116
|
+
/** Identifiers that can bring in directives to the template. */
|
|
117
|
+
export type DirectiveHostIdentifier = ElementIdentifier | TemplateNodeIdentifier | ComponentNodeIdentifier | DirectiveNodeIdentifier;
|
|
106
118
|
/**
|
|
107
119
|
* Describes the absolute byte offsets of a text anchor in a source code.
|
|
108
120
|
*/
|
|
109
121
|
export declare class AbsoluteSourceSpan {
|
|
110
|
-
start: number;
|
|
111
|
-
end: number;
|
|
122
|
+
readonly start: number;
|
|
123
|
+
readonly end: number;
|
|
112
124
|
constructor(start: number, end: number);
|
|
113
125
|
}
|
|
114
126
|
/**
|
|
@@ -5,7 +5,7 @@
|
|
|
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.dev/license
|
|
7
7
|
*/
|
|
8
|
-
import { DirectiveMeta as T2DirectiveMeta, Expression, SchemaMetadata } from '@angular/compiler';
|
|
8
|
+
import { DirectiveMeta as T2DirectiveMeta, Expression, SchemaMetadata, ExternalReference } from '@angular/compiler';
|
|
9
9
|
import ts from 'typescript';
|
|
10
10
|
import { Reference } from '../../imports';
|
|
11
11
|
import { ClassDeclaration } from '../../reflection';
|
|
@@ -241,6 +241,12 @@ export interface DirectiveMeta extends T2DirectiveMeta, DirectiveTypeCheckMeta {
|
|
|
241
241
|
* scope via `@Component.deferredImports` field.
|
|
242
242
|
*/
|
|
243
243
|
isExplicitlyDeferred: boolean;
|
|
244
|
+
/** Whether selectorless is enabled for the specific component. */
|
|
245
|
+
selectorlessEnabled: boolean;
|
|
246
|
+
/**
|
|
247
|
+
* Names of the symbols within the source file that are referenced directly inside the template.
|
|
248
|
+
*/
|
|
249
|
+
localReferencedSymbols: Set<string> | null;
|
|
244
250
|
}
|
|
245
251
|
/** Metadata collected about an additional directive that is being applied to a directive host. */
|
|
246
252
|
export interface HostDirectiveMeta {
|
|
@@ -251,7 +257,7 @@ export interface HostDirectiveMeta {
|
|
|
251
257
|
* which indicates the expression could not be resolved due to being imported from some external
|
|
252
258
|
* file. In this case, the expression is the raw expression as appears in the decorator.
|
|
253
259
|
*/
|
|
254
|
-
directive: Reference<ClassDeclaration> | Expression;
|
|
260
|
+
directive: Reference<ClassDeclaration> | Expression | ExternalReference;
|
|
255
261
|
/** Whether the reference to the host directive is a forward reference. */
|
|
256
262
|
isForwardReference: boolean;
|
|
257
263
|
/** Inputs from the host directive that have been exposed. */
|
|
@@ -300,7 +306,7 @@ export interface TemplateGuardMeta {
|
|
|
300
306
|
export interface PipeMeta {
|
|
301
307
|
kind: MetaKind.Pipe;
|
|
302
308
|
ref: Reference<ClassDeclaration>;
|
|
303
|
-
name: string;
|
|
309
|
+
name: string | null;
|
|
304
310
|
nameExpr: ts.Expression | null;
|
|
305
311
|
isStandalone: boolean;
|
|
306
312
|
isPure: boolean;
|
|
@@ -5,9 +5,10 @@
|
|
|
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.dev/license
|
|
7
7
|
*/
|
|
8
|
-
export { ComponentScopeKind, ComponentScopeReader, ExportScope, LocalModuleScope, ScopeData, StandaloneScope, } from './src/api';
|
|
8
|
+
export { ComponentScopeKind, ComponentScopeReader, ExportScope, LocalModuleScope, ScopeData, StandaloneScope, ComponentScope, } from './src/api';
|
|
9
9
|
export { CompoundComponentScopeReader } from './src/component_scope';
|
|
10
10
|
export { DtsModuleScopeResolver, MetadataDtsModuleScopeResolver } from './src/dependency';
|
|
11
11
|
export { DeclarationData, LocalModuleScopeRegistry, LocalNgModuleData } from './src/local';
|
|
12
|
+
export { SelectorlessComponentScopeReader } from './src/selectorless_scope';
|
|
12
13
|
export { TypeCheckScope, TypeCheckScopeRegistry } from './src/typecheck';
|
|
13
14
|
export { makeNotStandaloneDiagnostic, makeUnknownComponentImportDiagnostic } from './src/util';
|