jamesotron/hamlbars — pull request #31 by railsjedi (2012-08-08 11:11:25+00:00)
Title: Better handling of `hb 'else' do` blocks

An idea on using 'else' blocks with hamlbars.

https://gist.github.com/2992040

I personally think its way more readable when I can indent my else blocks. E.g.

= hb 'if content.condition1' do
= hb 'if content.condition2' do
%p Some paragraph
= hb 'else' do
%p another paragraph
= hb 'else' do
%p third paragraph

Let me know what you think. If you think this implementation is too hacky, and alternative would be to create a new helper `hb_else` that takes a block.