title: Angular2 - ng-class not applying css
body: <p>I'm just trying to implement a condition row formatting in a table but it is not working.  </p>
  
  <p>The code is very simple:</p>
  
  <h1>styles</h1>
  
  <pre><code>&lt;style type="text/css"&gt;
    .red {
      color: red;
    }
  
    .blue {
      color: blue;
    }
  &lt;/style&gt;
  </code></pre>
  
  <h1>html component</h1>
  
  <pre><code>&lt;tr *ngFor="let c of customers" [class.selected]="c === selectedItem" ng-class="{1==1 ? 'red': 'blue'}"&gt;
  </code></pre>
  
  <p>The condition <code>1==1</code> is always <code>true</code>, and should render the red class,  but it doesn't apply either red or blue class.</p>