@angular/compiler 19.0.0-rc.1 → 19.0.0-rc.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/fesm2022/compiler.mjs +17 -13
- package/fesm2022/compiler.mjs.map +1 -1
- package/index.d.ts +1 -1
- package/package.json +2 -2
package/fesm2022/compiler.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Angular v19.0.0-rc.
|
|
2
|
+
* @license Angular v19.0.0-rc.2
|
|
3
3
|
* (c) 2010-2024 Google LLC. https://angular.io/
|
|
4
4
|
* License: MIT
|
|
5
5
|
*/
|
|
@@ -26348,15 +26348,16 @@ function convertSourceSpan(span, baseSourceSpan) {
|
|
|
26348
26348
|
* workaround, because it'll include an additional text node as the first child. We can work
|
|
26349
26349
|
* around it here, but in a discussion it was decided not to, because the user explicitly opted
|
|
26350
26350
|
* into preserving the whitespace and we would have to drop it from the generated code.
|
|
26351
|
-
* The diagnostic mentioned point #1 will flag such cases to users.
|
|
26351
|
+
* The diagnostic mentioned point in #1 will flag such cases to users.
|
|
26352
26352
|
*
|
|
26353
26353
|
* @returns Tag name to be used for the control flow template.
|
|
26354
26354
|
*/
|
|
26355
26355
|
function ingestControlFlowInsertionPoint(unit, xref, node) {
|
|
26356
26356
|
let root = null;
|
|
26357
26357
|
for (const child of node.children) {
|
|
26358
|
-
// Skip over comment nodes
|
|
26359
|
-
|
|
26358
|
+
// Skip over comment nodes and @let declarations since
|
|
26359
|
+
// it doesn't matter where they end up in the DOM.
|
|
26360
|
+
if (child instanceof Comment$1 || child instanceof LetDeclaration$1) {
|
|
26360
26361
|
continue;
|
|
26361
26362
|
}
|
|
26362
26363
|
// We can only infer the tag name/attributes if there's a single root node.
|
|
@@ -26367,6 +26368,9 @@ function ingestControlFlowInsertionPoint(unit, xref, node) {
|
|
|
26367
26368
|
if (child instanceof Element$1 || (child instanceof Template && child.tagName !== null)) {
|
|
26368
26369
|
root = child;
|
|
26369
26370
|
}
|
|
26371
|
+
else {
|
|
26372
|
+
return null;
|
|
26373
|
+
}
|
|
26370
26374
|
}
|
|
26371
26375
|
// If we've found a single root node, its tag name and attributes can be
|
|
26372
26376
|
// copied to the surrounding template to be used for content projection.
|
|
@@ -30836,7 +30840,7 @@ function publishFacade(global) {
|
|
|
30836
30840
|
* @description
|
|
30837
30841
|
* Entry point for all public APIs of the compiler package.
|
|
30838
30842
|
*/
|
|
30839
|
-
const VERSION = new Version('19.0.0-rc.
|
|
30843
|
+
const VERSION = new Version('19.0.0-rc.2');
|
|
30840
30844
|
|
|
30841
30845
|
class CompilerConfig {
|
|
30842
30846
|
defaultEncapsulation;
|
|
@@ -32680,7 +32684,7 @@ const MINIMUM_PARTIAL_LINKER_DEFER_SUPPORT_VERSION = '18.0.0';
|
|
|
32680
32684
|
function compileDeclareClassMetadata(metadata) {
|
|
32681
32685
|
const definitionMap = new DefinitionMap();
|
|
32682
32686
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$5));
|
|
32683
|
-
definitionMap.set('version', literal('19.0.0-rc.
|
|
32687
|
+
definitionMap.set('version', literal('19.0.0-rc.2'));
|
|
32684
32688
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
32685
32689
|
definitionMap.set('type', metadata.type);
|
|
32686
32690
|
definitionMap.set('decorators', metadata.decorators);
|
|
@@ -32698,7 +32702,7 @@ function compileComponentDeclareClassMetadata(metadata, dependencies) {
|
|
|
32698
32702
|
callbackReturnDefinitionMap.set('ctorParameters', metadata.ctorParameters ?? literal(null));
|
|
32699
32703
|
callbackReturnDefinitionMap.set('propDecorators', metadata.propDecorators ?? literal(null));
|
|
32700
32704
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_DEFER_SUPPORT_VERSION));
|
|
32701
|
-
definitionMap.set('version', literal('19.0.0-rc.
|
|
32705
|
+
definitionMap.set('version', literal('19.0.0-rc.2'));
|
|
32702
32706
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
32703
32707
|
definitionMap.set('type', metadata.type);
|
|
32704
32708
|
definitionMap.set('resolveDeferredDeps', compileComponentMetadataAsyncResolver(dependencies));
|
|
@@ -32793,7 +32797,7 @@ function createDirectiveDefinitionMap(meta) {
|
|
|
32793
32797
|
const definitionMap = new DefinitionMap();
|
|
32794
32798
|
const minVersion = getMinimumVersionForPartialOutput(meta);
|
|
32795
32799
|
definitionMap.set('minVersion', literal(minVersion));
|
|
32796
|
-
definitionMap.set('version', literal('19.0.0-rc.
|
|
32800
|
+
definitionMap.set('version', literal('19.0.0-rc.2'));
|
|
32797
32801
|
// e.g. `type: MyDirective`
|
|
32798
32802
|
definitionMap.set('type', meta.type.value);
|
|
32799
32803
|
if (meta.isStandalone !== undefined) {
|
|
@@ -33212,7 +33216,7 @@ const MINIMUM_PARTIAL_LINKER_VERSION$4 = '12.0.0';
|
|
|
33212
33216
|
function compileDeclareFactoryFunction(meta) {
|
|
33213
33217
|
const definitionMap = new DefinitionMap();
|
|
33214
33218
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$4));
|
|
33215
|
-
definitionMap.set('version', literal('19.0.0-rc.
|
|
33219
|
+
definitionMap.set('version', literal('19.0.0-rc.2'));
|
|
33216
33220
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
33217
33221
|
definitionMap.set('type', meta.type.value);
|
|
33218
33222
|
definitionMap.set('deps', compileDependencies(meta.deps));
|
|
@@ -33247,7 +33251,7 @@ function compileDeclareInjectableFromMetadata(meta) {
|
|
|
33247
33251
|
function createInjectableDefinitionMap(meta) {
|
|
33248
33252
|
const definitionMap = new DefinitionMap();
|
|
33249
33253
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$3));
|
|
33250
|
-
definitionMap.set('version', literal('19.0.0-rc.
|
|
33254
|
+
definitionMap.set('version', literal('19.0.0-rc.2'));
|
|
33251
33255
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
33252
33256
|
definitionMap.set('type', meta.type.value);
|
|
33253
33257
|
// Only generate providedIn property if it has a non-null value
|
|
@@ -33298,7 +33302,7 @@ function compileDeclareInjectorFromMetadata(meta) {
|
|
|
33298
33302
|
function createInjectorDefinitionMap(meta) {
|
|
33299
33303
|
const definitionMap = new DefinitionMap();
|
|
33300
33304
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$2));
|
|
33301
|
-
definitionMap.set('version', literal('19.0.0-rc.
|
|
33305
|
+
definitionMap.set('version', literal('19.0.0-rc.2'));
|
|
33302
33306
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
33303
33307
|
definitionMap.set('type', meta.type.value);
|
|
33304
33308
|
definitionMap.set('providers', meta.providers);
|
|
@@ -33331,7 +33335,7 @@ function createNgModuleDefinitionMap(meta) {
|
|
|
33331
33335
|
throw new Error('Invalid path! Local compilation mode should not get into the partial compilation path');
|
|
33332
33336
|
}
|
|
33333
33337
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$1));
|
|
33334
|
-
definitionMap.set('version', literal('19.0.0-rc.
|
|
33338
|
+
definitionMap.set('version', literal('19.0.0-rc.2'));
|
|
33335
33339
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
33336
33340
|
definitionMap.set('type', meta.type.value);
|
|
33337
33341
|
// We only generate the keys in the metadata if the arrays contain values.
|
|
@@ -33382,7 +33386,7 @@ function compileDeclarePipeFromMetadata(meta) {
|
|
|
33382
33386
|
function createPipeDefinitionMap(meta) {
|
|
33383
33387
|
const definitionMap = new DefinitionMap();
|
|
33384
33388
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION));
|
|
33385
|
-
definitionMap.set('version', literal('19.0.0-rc.
|
|
33389
|
+
definitionMap.set('version', literal('19.0.0-rc.2'));
|
|
33386
33390
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
33387
33391
|
// e.g. `type: MyPipe`
|
|
33388
33392
|
definitionMap.set('type', meta.type.value);
|