mirror of
https://github.com/angular/angular
synced 2026-05-24 09:28:37 +00:00
Currently the ImportManager class handles various rewriting actions of imports when compiling @angular/core. This is required as code compiled within @angular/core cannot import from '@angular/core'. To work around this, imports are rewritten to get core symbols from a particular file, r3_symbols.ts. In this refactoring, this rewriting logic is moved out of the ImportManager and put behind an interface, ImportRewriter. There are three implementers of the interface: * NoopImportRewriter, used for compiling all non-core packages. * R3SymbolsImportRewriter, used when ngtsc compiles @angular/core. * NgccFlatImportRewriter, used when ngcc compiles @angular/core (special logic is needed because ngcc has to rewrite imports in flat bundles differently than in non-flat bundles). This is a precursor to using this rewriting logic in other contexts besides the ImportManager. PR Close #27998 |
||
|---|---|---|
| .. | ||
| integrationtest | ||
| src | ||
| test | ||
| browser-rollup.config.js | ||
| BUILD.bazel | ||
| DEVELOPER.md | ||
| index.ts | ||
| ngtools2.ts | ||
| package.json | ||
| tsconfig-build.json | ||
| tsconfig.json | ||