Jade.js tables and variables
===

I'm having issues where I can easily create a table in Jade if I use a variable that I've defined on the page, but as soon as I try to use anything else it prints a long table of nothing.

For instance I can produce a table with the below code:

    table
      thead
        tr
          th Bid ID
          th Bid Value
      tbody
        items = [ {"bid_id":1, "bid_value":1.63},{"bid_id":2, "bid_value":1.75},{"bid_id":3, "bid_value":1.00} ]
        each item, i in items
          tr
            td #{item.bid_id}
            td #{item.bid_value}

However when I try to use the following I get a very long table that's completely empty!

    table
      thead
        tr
          th Bid ID
          th Bid Value
      tbody
        items = all_bids
        each item, i in items
          tr
            td #{item.bid_id}
            td #{item.bid_value}

all_bids contains the exact same JSON as defined explicitly above. If I print it in the Jade view using:

    p= all_bids

It prints the array correctly as:

[ {"bid_id":1, "bid_value":1.63},{"bid_id":2, "bid_value":1.75},{"bid_id":3, "bid_value":1.00} ]

Struggling to find any decent documentation on creating tables in Jade so any help would be appreciated!

Thanks!