Previously, `QueryEngine` invoked `AnalysisHost::resolve` directly on every syntactic dependency scan, cross-file constant evaluation, export-map walk, and NgModule scope traversal without an engine-level cache. For asynchronous bundler hosts, repeating identical `(importer, specifier, kind, type_only, attributes)` lookups across queries and rebuilds would generate redundant cross-boundary round-trips. In addition, failed module resolutions only recorded `UNRESOLVED_IMPORTS_FILE_ID` during the Stage-1 static dependency scan of `.ts` sources. That scan does not resolve the specifiers of `.d.ts` files, so a failed lookup made from one, such as a re-export to a missing target, was untracked and not re-run when the target was later created. Deleting a resolved file also left importers holding stale cached dependency edges. Introduce `ResolutionCache` on `QueryEngine` to memoize completed module resolution outcomes per importer `FileId` and request key while maintaining both a target-to-importer reverse index and an unresolved-importer index. Route query-time module lookups through `QueryContext::resolve_request`, `resolve_from_id`, and `resolve_from_path` so every resolution records the importer dependency and every failed lookup—including negative cache hits— records `UNRESOLVED_IMPORTS_FILE_ID`. Classify pure re-exports in `analyze_file_syntax` with `ImportKind::ReExport` so syntactic dependency discovery shares cached resolutions with cross-file evaluation and export-map queries. On `invalidate_file_id`, drop only the edited importer's cached resolutions so edits to a leaf module preserve cached resolutions across its importers. On `FileUpdateType::Deleted`, evict queries derived from importers that had resolved to the deleted target while keeping their `ParseFile` results cached. On `invalidate_module_resolution`, stop serving every cached resolution and re-run importers with previously unresolved specifiers. The superseded entries are kept as stale rather than dropped, so the reverse index still covers importers whose queries stay cached and that therefore do not resolve again, and a lookup that the host answers after the change is not memoized. When a host resolution changes a module's `IdKind`, also evict the importers whose cached resolutions report the previous kind. The resolution that changed the kind is not memoized, so the query re-run that follows asks the host again.
Angular - The modern web developer's platform
Angular is a development platform for building mobile and desktop web applications
using TypeScript/JavaScript and other languages.
Contributing Guidelines
·
Submit an Issue
·
Blog
Documentation
Get started with Angular, learn the fundamentals and explore advanced topics on our documentation website.
Advanced
Local Development
To contribute to the Angular Docs, check out the Angular.dev README
Development Setup
Prerequisites
- Install Node.js which includes Node Package Manager
Setting Up a Project
Install the Angular CLI globally:
npm install -g @angular/cli
Create a workspace:
ng new [PROJECT NAME]
Run the application:
cd [PROJECT NAME]
ng serve
Angular is cross-platform, fast, scalable, has incredible tooling, and is loved by millions.
Quickstart
Ecosystem
Changelog
Learn about the latest improvements.
Upgrading
Check out our upgrade guide to find out the best way to upgrade your project.
Contributing
Contributing Guidelines
Read through our contributing guidelines to learn about our submission process, coding rules, and more.
Want to Help?
Want to report a bug, contribute some code, or improve the documentation? Excellent! Read up on our guidelines for contributing and then check out one of our issues labeled as help wanted or good first issue.
Code of Conduct
Help us keep Angular open and inclusive. Please read and follow our Code of Conduct.
Community
Join the conversation and help the community.
- X (formerly Twitter)
- Bluesky
- Discord
- YouTube
- StackOverflow
- Find a Local Meetup
Love Angular? Give our repo a star ⭐ ⬆️.
