title: passing parameter to mat-dialog open method
body: <p><strong>Angular 7.1</strong> , 
  <strong>AngularMaterial 7.3</strong></p>
  
  <p>I am trying to call function and pass some value, It prompt following error </p>
  
  <blockquote>
    <p>No component factory found for t1. Did you add it to @NgModule.entryComponents?</p>
  </blockquote>
  
  <p>Although <code>t1</code> is included in <code>entryComponent</code>. but once remove passing value to fix value it will work.</p>
  
  <pre><code>  &lt;button mat-button (click)="openDialog('t1')"&gt;T1&lt;/button&gt;
    &lt;button mat-button (click)="openDialog('t2')"&gt;T2&lt;/button&gt;
  </code></pre>
  
  <p>Once I pass value its show the above code.</p>
  
  <pre><code>  openDialog(e) {
      console.log(e);
      const dialogRef = this.dialog.open(e);
      dialogRef.afterClosed().subscribe(result =&gt; {
        console.log(`Dialog result: ${result}`);
        dialogRef == null
      });
    }
  
  @Component({
    selector: 't1',
    templateUrl: 't1.html',
  })
  export class t1 {}
  
  @Component({
    selector: 't2',
    templateUrl: 't2.html',
  })
  export class t2 {}
  </code></pre>
  
  <p>but once I remove the value and fix <code>dialogRef.open</code>, it works fine</p>
  
  <pre><code>const dialogRef = this.dialog.open(t1);
  </code></pre>