AOT Notes

April 9, 2020 · View on GitHub

About barred latin O(ɵ)

https://github.com/angular/angular/issues/16583#issuecomment-353514810

https://github.com/angular/angular/issues/18018#issuecomment-316031479

https://github.com/angular/material2/blob/master/tools/package-tools/compile-entry-point.ts#L30

The prefixed symbols are indeed private (see documentation). The must be exported because they are being used by the code generated by the AOT compiler.

Bad

/x-module/index.ts

export * from './x-module';

/x-module/x-module.ts

export class XModule {}

/index.ts

export * from './root-module';
export * from './x-module';

/root-module.ts

//bad
import { XModule } from './x-module/x-module';
export class RootModule {}

Good

/x-module/index.ts

export * from './x-module';

/x-module/x-module.ts

export class XModule {}

/index.ts

export * from './root-module';
export * from './x-module';

/root-module.ts

//good
import { XModule } from './x-module';
export class RootModule {}