Skip to content

Invalid templates produce no diagnostic (parse errors swallowed) #290

@brandonroberts

Description

@brandonroberts

Malformed templates are silently accepted — result.errors is empty. (Also covers ambiguous DI unions A | B, which should emit a "not supported as injection token" diagnostic rather than a silent invalid factory.)

Repro

import { Component } from '@angular/core';
@Component({ selector: 'app-bad', template: '<div><span></div>' })
export class BadComponent {}

Actual

Compiles without populating result.errors; the parse error is swallowed.

Expected

Unclosed/malformed tags surface a template parse diagnostic in result.errors.

Impact

Silently-wrong output with no compile-time signal — a debugging trap.


Researched and drafted with Claude Code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Priority

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions