You wrote:
= hb 'if content.condition1' do
= hb 'if content.condition2' do
%p Some paragraph
= hb 'else'
%p another paragraph
= hb 'else'
%p third paragraph
Correct code:
= hb 'if content.condition1' do
= hb 'if content.condition2' do
%p Some paragraph
= hb 'else'
%p another paragraph
= hb 'else'
%p third paragraph
The reason for this is actually a haml syntax issue, not a hamlbars one. You cannot nest under a ruby statement unless you're passing in a block. Since {{else}}
is not a handlebars block statement you don't pass in a block. Haml would help a lot if it threw the a similar error to the one it throws when you try and nest under plain text.
Even though it's ugly this should be in the README. This isn't shameful, you do the best you can do with what you're given. If people don't like it they can go back to normal handlebars with it's ERBish syntax.