I have rails helpers (hs_if
, hs_else
):
= hs_if :current_user do
Hello, {{ current_user/name }}!
= hs_else do
= link_to Sign In , sign_in_path
...which produces handlebars templates:
{{#if current_user}}
Hello, {{ current_user/name }}!
{{else}}
<a href="/signin">Sign In</a>
{{/if}}
How can I render {{#if current_user}} ... {{else}} ... {{/if}}
without nesting hs_else
in hs_if
?
I think I should remove {{/if}}
from output, but I can t find way to do it in helper.