Hi,

I was reading the angular 2 guide and I have a question with class binding

https://angular.io/docs/ts/latest/guide/template-syntax.html#!#class-binding

<!-- reset/override all class names with a binding  -->
<div class="bad curly special"
     [class]="badCurly">Bad curly</div>

Why we can bind the attribute "class"?

The guide tell us that we can bind the DOM properties, but not the HTML 
attributes:

https://angular.io/docs/ts/latest/guide/template-syntax.html#!#html-attribute-vs-dom-property

So, why [class] works? Should it be [className]?

Why angular doesn't throw an exception like colspan 
<https://angular.io/docs/ts/latest/guide/template-syntax.html#%21#attribute-binding>
?

Template parse errors:
> Can't bind to 'colspan' since it isn't a known native property
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to