title: click event is not working in innerhtml string angular 6
body: <p>I am working on an generate dynamic template using angular 6. I have an API that return strings like below:</p>
  
  <pre class="lang-html prettyprint-override"><code>    &lt;button type="button" (click)="openAlert()"&gt;click me&lt;/button&gt;
  </code></pre>
  
  <p>and html</p>
  
  <pre class="lang-html prettyprint-override"><code>    &lt;div [innerHtml]="myTemplate | safeHtml"&gt;
        &lt;/div&gt;
  </code></pre>
  
  <p>function is bellow:</p>
  
  <pre class="lang-js prettyprint-override"><code>    openAlert() {
          alert('hello');
        }
  </code></pre>