Is this sass code valid?
tr:nth-child(odd)
:background-color #cccccc
Somehow, it does not color my table's alternating rows.
Is this sass code valid?
tr:nth-child(odd)
:background-color #cccccc
Somehow, it does not color my table's alternating rows.
What browser are you using? nth-child
isn't presently supported in Firefox, or IE. You'll probably have to use the old odd/even classes thing.
Compass provides mixins for styling your tables with sass, it requires some extra css classes due to poor support of CSS3.
See the Table Utilities section of wiki docs for more information. A demo is here.