angular/goldens/public-api/compiler-cli
leonsenft d596d8bd0a refactor(compiler): support matching and validating foreign components in templates (#68674)
We extract the identifier name from the `foreignImports` expression in
`ComponentDecoratorHandler` and use a `SelectorlessMatcher` to match element
tags against these names. If an element matches both a regular Angular
directive and a foreign component, a conflict error is thrown.

In addition, we implement strict template semantic validation for these matched
foreign components within `TemplateSemanticsChecker`. Elements matched as
foreign components only support static attributes and property bindings. Any
event bindings, template references, or non-property input bindings (e.g.
class, style, or attribute bindings) trigger a semantic error diagnostic.

Finally, we skip standard DOM schema checks for foreign components to prevent spurious
validation errors since foreign components are not defined in standard HTML schemas.

PR Close #68674
2026-05-19 13:42:10 -07:00
..
compiler_options.api.md feat(compiler): Angular expressions with optional chaining returns undefined 2026-04-28 15:26:53 -07:00
error_code.api.md refactor(compiler): support matching and validating foreign components in templates (#68674) 2026-05-19 13:42:10 -07:00
extended_template_diagnostic_name.api.md feat(compiler-cli): Adds diagnostic for misconfigured @defer triggers (#64069) 2025-10-13 11:06:01 -07:00