Fork me on GitHub

I've got a question: I want to have an expanding table (let's say html table). Each row in the table takes a map M with keys K. Usually the row will show a few keys from M, but when I click the row it should show all the keys.


If i wasn't using a table, I would use something like:

[:div [show-some-keys M] 
      (when condition? [other-keys M]]


but since it's a table, I'm returning a tr


I'm calling display-m from here:

[:table [:tbody (for [M data] [display-m M] )]]
So I am forced to return one tr, but i'd really like to be able to return two trs, one that's hidden unless condition?.


Welp, went with divs so i can group them however and return "1" thing like: [:div thing1 thing2]