ngStyle and ngClass in Angular 2
<p>I'm not sure how to use <code>ngStyle</code> directive with latest beta-12. Could someone please clarify.</p>

<p>The plnkr link in Angular docs <a href="https://angular.io/docs/js/latest/api/common/NgStyle-directive.html" rel="nofollow noreferrer">https://angular.io/docs/js/latest/api/common/NgStyle-directive.html</a> is outdated, it uses alpha build. </p>

<p>I tried these syntax but does not seem to work. I  </p>

<pre><code> [ngStyle]="{'display': none}"
 [style.display]="none"
</code></pre>

<p><a href="http://plnkr.co/edit/U9EJuIhFqxY9t2sULMdw" rel="nofollow noreferrer">http://plnkr.co/edit/U9EJuIhFqxY9t2sULMdw</a></p>

<pre><code>import {Component} from 'angular2/core'

@Component({
  selector: 'my-app',
  providers: [],
  template: `
    &lt;div&gt;
      &lt;h2 [ngStyle]="{'display': none}"&gt;Hello {{name}}&lt;/h2&gt;
      &lt;h2 [style.display]="none"&gt;Hello {{name}}&lt;/h2&gt;
    &lt;/div&gt;
  `,
  directives: []
})
export class App {
  constructor() {
    this.name = 'Angular2'
  }
}
</code></pre>