debian-mirror-gitlab/app/helpers/external_link_helper.rb
2021-01-30 21:13:32 +05:30

9 lines
262 B
Ruby

# frozen_string_literal: true
module ExternalLinkHelper
def external_link(body, url, options = {})
link_to url, { target: '_blank', rel: 'noopener noreferrer' }.merge(options) do
"#{body} #{sprite_icon('external-link')}".html_safe
end
end
end