Architecture: Can AOT compilation fully eliminate @angular/compiler at run...

Documentation for Sessions

🏗️ Architecture: Can AOT compilation fully eliminate @angular/compiler at run...

Date: 2026-03-24
Time: 19:24:21 UTC
Session: gspace1-267.6
Agent: angular
Confidence: 95%
Status: ✅ Documented


📋 Decision Context

Question:

Can AOT compilation fully eliminate @angular/compiler at runtime?

Task: S267 AOT browser integration testing


🎯 Decision Made

Chosen:

No. AOT strategy must be HYBRID — pre-compile user templates but still load @angular/compiler for library code. Angular packages (HttpClient, Router, Forms) ship as partially-compiled and need JIT fallback.

Options Considered:


💭 Reasoning

Angular library packages use ɵɵngDeclareFactory which requires the compiler facade. Until we integrate the Angular Linker (which pre-processes library code), the compiler cannot be eliminated. compilerEliminated must always be false in hybrid mode.


📁 Files Involved


🔗 Related


Auto-generated by MCP Smart Consolidation