feat(ivy): support bootstrap in ngModuleDef (#25775)

The bootstrap property of @NgModule was not previously compiled by
the compiler in AOT or JIT modes (in Ivy). This commit adds support
for bootstrap.

PR Close #25775
This commit is contained in:
Alex Rickabaugh
2018-08-28 14:19:33 -07:00
committed by Igor Minar
parent a0c4b2d8f0
commit 13ccdfd89d
4 changed files with 12 additions and 5 deletions

View File

@ -182,6 +182,7 @@ describe('ngtsc behavioral tests', () => {
@NgModule({
declarations: [TestCmp],
bootstrap: [TestCmp],
})
export class TestModule {}
`);
@ -193,7 +194,7 @@ describe('ngtsc behavioral tests', () => {
const jsContents = getContents('test.js');
expect(jsContents)
.toContain(
'i0.ɵdefineNgModule({ type: TestModule, bootstrap: [], ' +
'i0.ɵdefineNgModule({ type: TestModule, bootstrap: [TestCmp], ' +
'declarations: [TestCmp], imports: [], exports: [] })');
const dtsContents = getContents('test.d.ts');