Module: Jekyll::Locale::Support
- Defined in:
- lib/jekyll/locale/mixins/support.rb
Instance Attribute Summary collapse
-
#locale ⇒ Object
readonly
Returns the value of attribute locale.
-
#site ⇒ Object
readonly
Returns the value of attribute site.
Instance Method Summary collapse
Instance Attribute Details
#locale ⇒ Object (readonly)
Returns the value of attribute locale.
5 6 7 |
# File 'lib/jekyll/locale/mixins/support.rb', line 5 def locale @locale end |
#site ⇒ Object (readonly)
Returns the value of attribute site.
5 6 7 |
# File 'lib/jekyll/locale/mixins/support.rb', line 5 def site @site end |
Instance Method Details
#hreflangs ⇒ Object
11 12 13 14 15 16 17 18 19 |
# File 'lib/jekyll/locale/mixins/support.rb', line 11 def hreflangs @hreflangs ||= locale_pages.map do |locale_page| { "locale" => locale_page.locale, "relation" => "alternate", "url" => locale_page.url, } end end |
#locale_pages ⇒ Object
21 22 23 |
# File 'lib/jekyll/locale/mixins/support.rb', line 21 def locale_pages @locale_pages ||= [] end |
#setup_hreflangs? ⇒ Boolean
7 8 9 |
# File 'lib/jekyll/locale/mixins/support.rb', line 7 def setup_hreflangs? false end |