Class | Compass::Configuration::Data
In: | lib/compass/configuration/data.rb
Parent: | Object

The Compass configuration data storage class manages configuration data that comes from a variety of different sources and aggregates them together into a consistent API Some of the possible sources of configuration data:

      * Compass default project structure for stand alone projects
      * App framework specific project structures for rails, etc.
      * User supplied explicit configuration
      * Configuration data provided via the command line interface

There are two kinds of configuration data that doesn‘t come from the user:

1. Configuration data that is defaulted as if the user had provided it themselves. This is useful for providing defaults that the user is likely to want to edit but shouldn‘t have to provide explicitly when getting started
2. Configuration data that is defaulted behind the scenes because some value is required.

### Methods

add_import_path asset_cache_buster asset_host discover load new relative_assets? require set_all watch watches

### Included Modules

Compass::Configuration::Inheritance Compass::Configuration::Serialization Compass::Configuration::Adapters

### Attributes

name | [R] |

### Public Class methods

new(name, attr_hash = nil)

### Public Instance methods

add_import_path(*paths)
asset_cache_buster(simple = nil, &block)

When called with a block, defines the cache buster strategy to be used. If the block returns nil or a string, then it is appended to the url as a query parameter. In this case, the returned string must not include the starting ’?’. The block may also return a hash with :path and/or :query values and it will replace the original path and query string with the busted values returned. The block will be passed the root-relative url of the asset. If the block accepts two arguments, it will also be passed a File object that points to the asset on disk — which may or may not exist. When called without a block, returns the block that was previously set.

To disable the asset cache buster:

        asset_cache_buster :none

asset_host(&block)

When called with a block, defines the asset host url to be used. The block must return a string that starts with a protocol (E.g. http). The block will be passed the root-relative url of the asset. When called without a block, returns the block that was previously set.

discover(frameworks_dir)

Finds all extensions within a directory and registers them.

load(framework_dir)
relative_assets?()
require(lib)

Require a compass plugin and capture that it occured so that the configuration serialization works next time.

set_all(attr_hash)
watch(glob, &block)
watches()

[Validate]