In this post I will go through using grunt for our css minification task and also showcase another preprocessor for css called less. First off lets start with a express 4 application, we will create it with Visual Studio NTVS, the latest RC contains a template for express 4. We can install grunt by command […]
Tag: css
So you want to use Spark View Engine: Highlight Table Alt Row. Here is how one highlights an alt row with spark, quite clean I tell you. Assuming you have a css that like below.
1 2 3 4 5 6 |
tr.alt { text-align: left; padding: 2px; border: 1px solid #000; background: #ADDFFF; } |
And in your template you will call it like this.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
<table> <tr> <th>ID</th> <th>FirstName</th> <th>LastName</th> <th>Gender</th> </tr> <tr each="var person in people" class="alt?{personIndex % 2 == 0}"> <td>${person.Id}</td> <td>${person.FirstName}</td> <td>${person.LastName}</td> <td>${person.Gender}</td> </tr> </table> |
Note: How I am using personIndex. It basically […]