Analyze external template (from templateUrl) and return ONLY what's used.
Loads the external template file and analyzes it using the three-tier strategy.
Component class declaration
Template URL from @Component metadata (e.g., './user.component.html')
Absolute path to the component file
All imports from parent NgModule
ts-morph Project (for selector mapping)
Array of actually-used import names
Analyze template and return ONLY what's actually used.
Uses three-tier strategy for optimal performance:
Component class declaration
Template HTML content
All imports from parent NgModule
ts-morph Project (for selector mapping)
Array of actually-used import names
Template Usage Analyzer with Three-Tier Strategy.
Analyzes Angular templates to determine which imports are actually used. Uses a progressive enhancement approach for optimal performance.