Class: Seorel::Controller::Params
- Inherits:
-
Object
- Object
- Seorel::Controller::Params
- Includes:
- ActiveSupport::Configurable
- Defined in:
- lib/seorel/controller/params.rb
Instance Method Summary collapse
- #description ⇒ Object
- #image ⇒ Object
-
#initialize(controller = nil) ⇒ Params
constructor
A new instance of Params.
- #keywords ⇒ Object
- #open_graph_extras ⇒ Object
- #page_text ⇒ Object
- #title ⇒ Object
- #twitter_extras ⇒ Object
Constructor Details
#initialize(controller = nil) ⇒ Params
Returns a new instance of Params.
15 16 17 |
# File 'lib/seorel/controller/params.rb', line 15 def initialize(controller = nil) @controller = controller end |
Instance Method Details
#description ⇒ Object
34 35 36 37 38 39 40 41 |
# File 'lib/seorel/controller/params.rb', line 34 def description [ lookup_prepend_description, base_description, page_text, lookup_append_description ].compact.join.html_safe end |
#image ⇒ Object
47 48 49 |
# File 'lib/seorel/controller/params.rb', line 47 def image config.image || .default_image end |
#keywords ⇒ Object
43 44 45 |
# File 'lib/seorel/controller/params.rb', line 43 def keywords .default_keywords end |
#open_graph_extras ⇒ Object
51 52 53 |
# File 'lib/seorel/controller/params.rb', line 51 def open_graph_extras . end |
#page_text ⇒ Object
19 20 21 22 23 |
# File 'lib/seorel/controller/params.rb', line 19 def page_text return unless available_pagination? .pagination_format.gsub('%page%', pagination_page) end |
#title ⇒ Object
25 26 27 28 29 30 31 32 |
# File 'lib/seorel/controller/params.rb', line 25 def title [ lookup_prepend_title, base_title, page_text, lookup_append_title ].compact.join.html_safe end |
#twitter_extras ⇒ Object
55 56 57 |
# File 'lib/seorel/controller/params.rb', line 55 def twitter_extras . end |