Class: LowVoltage::Configuration
- Inherits:
-
Object
- Object
- LowVoltage::Configuration
- Defined in:
- lib/low_voltage/configuration.rb
Instance Attribute Summary collapse
-
#content_path ⇒ Object
Returns the value of attribute content_path.
-
#layout ⇒ Object
Returns the value of attribute layout.
-
#posts_per_page ⇒ Object
Returns the value of attribute posts_per_page.
-
#use_action_caching ⇒ Object
Returns the value of attribute use_action_caching.
-
#use_routes ⇒ Object
Returns the value of attribute use_routes.
Instance Method Summary collapse
- #full_content_path ⇒ Object
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
5 6 7 8 9 10 11 |
# File 'lib/low_voltage/configuration.rb', line 5 def initialize @layout = "application" @content_path = "posts" @use_routes = true @use_action_caching = true @posts_per_page = 10 end |
Instance Attribute Details
#content_path ⇒ Object
Returns the value of attribute content_path.
3 4 5 |
# File 'lib/low_voltage/configuration.rb', line 3 def content_path @content_path end |
#layout ⇒ Object
Returns the value of attribute layout.
3 4 5 |
# File 'lib/low_voltage/configuration.rb', line 3 def layout @layout end |
#posts_per_page ⇒ Object
Returns the value of attribute posts_per_page.
3 4 5 |
# File 'lib/low_voltage/configuration.rb', line 3 def posts_per_page @posts_per_page end |
#use_action_caching ⇒ Object
Returns the value of attribute use_action_caching.
3 4 5 |
# File 'lib/low_voltage/configuration.rb', line 3 def use_action_caching @use_action_caching end |
#use_routes ⇒ Object
Returns the value of attribute use_routes.
3 4 5 |
# File 'lib/low_voltage/configuration.rb', line 3 def use_routes @use_routes end |
Instance Method Details
#full_content_path ⇒ Object
13 14 15 |
# File 'lib/low_voltage/configuration.rb', line 13 def full_content_path Rails.root.join("app/views/#{LowVoltage.configuration.content_path}/*.md") end |