Module: Rack::Less
- Defined in:
- lib/rack/less.rb,
lib/rack/less/version.rb,
lib/rack/less/response.rb,
lib/rack/less/request.rb,
lib/rack/less/options.rb,
lib/rack/less/source.rb,
lib/rack/less/config.rb,
lib/rack/less/base.rb
Overview
Defined Under Namespace
Modules: Options Classes: Base, Config, Request, Response, Source
Constant Summary collapse
Class Method Summary collapse
-
.cache_bust ⇒ Object
Cache bust config convenience method.
-
.combinations(key = nil) ⇒ Object
Combinations config convenience method.
- .config ⇒ Object
- .config=(value) ⇒ Object
-
.configure {|@@config| ... } ⇒ Object
Configuration accessors for Rack::Less (see config.rb for details).
-
.new(app, options = {}, &block) ⇒ Object
Create a new Rack::Less middleware component => the
options
Hash can be used to specify default configuration values => (see Rack::Less::Options for possible key/values). -
.stylesheet(key) ⇒ Object
Stylesheet helper, config convenience method.
Class Method Details
.cache_bust ⇒ Object
Cache bust config convenience method
53 54 55 |
# File 'lib/rack/less.rb', line 53 def cache_bust @@config.cache_bust end |
.combinations(key = nil) ⇒ Object
Combinations config convenience method
43 44 45 |
# File 'lib/rack/less.rb', line 43 def combinations(key=nil) @@config.combinations(key) end |
.config ⇒ Object
35 36 37 |
# File 'lib/rack/less.rb', line 35 def config @@config end |
.config=(value) ⇒ Object
38 39 40 |
# File 'lib/rack/less.rb', line 38 def config=(value) @@config = value end |
.configure {|@@config| ... } ⇒ Object
Configuration accessors for Rack::Less (see config.rb for details)
32 33 34 |
# File 'lib/rack/less.rb', line 32 def configure yield @@config if block_given? end |
.new(app, options = {}, &block) ⇒ Object
Create a new Rack::Less middleware component
> the options
Hash can be used to specify default configuration values
> (see Rack::Less::Options for possible key/values)
62 63 64 |
# File 'lib/rack/less.rb', line 62 def self.new(app, ={}, &block) Base.new(app, , &block) end |
.stylesheet(key) ⇒ Object
Stylesheet helper, config convenience method
48 49 50 |
# File 'lib/rack/less.rb', line 48 def stylesheet(key) @@config.stylesheet(key) end |