Class: Plato::ConfigDSL
- Inherits:
-
Object
- Object
- Plato::ConfigDSL
- Defined in:
- lib/plato/config.rb
Instance Method Summary collapse
-
#base_url(url) ⇒ Object
(also: #url)
Config DSL.
- #content(name, content_path_template, opts = {}) ⇒ Object
- #options(hash) ⇒ Object
Instance Method Details
#base_url(url) ⇒ Object Also known as: url
Config DSL
29 30 31 |
# File 'lib/plato/config.rb', line 29 def base_url(url) @base_url = url end |
#content(name, content_path_template, opts = {}) ⇒ Object
38 39 40 41 42 43 |
# File 'lib/plato/config.rb', line 38 def content(name, content_path_template, opts = {}) @content_categories ||= {} @content_categories[name.to_s] = ContentCategory.new(name, content_path_template, opts[:to] || content_path_template, opts[:sort], opts[:template]) end |
#options(hash) ⇒ Object
34 35 36 |
# File 'lib/plato/config.rb', line 34 def (hash) @options = hash end |