Module: Metanol::Helpers
- Defined in:
- lib/metanol/helpers.rb
Instance Method Summary collapse
-
#current_url ⇒ Object
Return a current URL.
-
#metanol_og_tags ⇒ Object
Render OpenGraph meta tags.
-
#metanol_tags ⇒ Object
Render all meta tags.
Instance Method Details
permalink #current_url ⇒ Object
Return a current URL
35 36 37 |
# File 'lib/metanol/helpers.rb', line 35 def current_url request.original_url end |
permalink #metanol_og_tags ⇒ Object
Render OpenGraph meta tags
13 14 15 16 17 |
# File 'lib/metanol/helpers.rb', line 13 def result = ::Metanol::Meta::OpenGraph result << ::Metanol::Meta::OpenGraph.render_current_url(current_url) result.html_safe end |
permalink #metanol_tags ⇒ Object
Render all meta tags
4 5 6 7 8 9 10 |
# File 'lib/metanol/helpers.rb', line 4 def result = '' SUPPORT_GROUPS.keys.each do |type| result << send("metanol_#{type}_tags") end result.html_safe end |