Skip to content

Instantly share code, notes, and snippets.

@remigijusj
Created January 15, 2013 12:39
Show Gist options
  • Save remigijusj/4538360 to your computer and use it in GitHub Desktop.
Save remigijusj/4538360 to your computer and use it in GitHub Desktop.
better helper?
# WHICH IS BETTER HELPER?
# -----------------
%Q{
<div class="invitation-info-box clearfix"><p>
#{invite_friends_link}
#{t('app.invitation.info_box_signed_in')}
</p></div>
}.html_safe
# -----------------
content_tag(:div,
content_tag(:p,
[
invite_friends_link,
t('app.invitation.info_box_signed_in')
].join.html_safe
),
:class => 'invitation-info-box clearfix')
# -----------------
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment