how can I iterate over the results of mysql query using jade. I am using node-mysql .
[
{
twitter_id: 52653645,
screen_name: 'somoething',
retweeted: '0'
},
{
twitter_id: 5265343636,
screen_name: 'somoet',
retweeted: '45'
},
]
Thanks
You can do it like I do here, when I generate the XML feed for my blog.
ul
- each result in results
li= result.twitter_id
li= result.screen_name
li= result.retweeted
Where results
is your array of MySQL results passed into the template.