Module: ComponentLibrary

Defined in:
lib/component_library.rb,
lib/component_library/engine.rb,
lib/component_library/version.rb

Defined Under Namespace

Classes: Configuration, Engine, InstallGenerator

Constant Summary collapse

VERSION =
"2.0.1"

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.configurationObject

Returns the value of attribute configuration.



6
7
8
# File 'lib/component_library.rb', line 6

def configuration
  @configuration
end

Class Method Details

.configure {|configuration| ... } ⇒ Object

Yields:



15
16
17
18
# File 'lib/component_library.rb', line 15

def self.configure(&block)
  self.configuration ||= Configuration.new
  yield(configuration)
end

.javascript_pathObject



28
29
30
# File 'lib/component_library.rb', line 28

def self.javascript_path
  '_component_library/library'
end

.resetObject



20
21
22
# File 'lib/component_library.rb', line 20

def self.reset
  @configuration = Configuration.new
end

.setup {|configuration| ... } ⇒ Object

Yields:



9
10
11
12
13
# File 'lib/component_library.rb', line 9

def self.setup(&block)
  puts "DEPRECATION NOTICE: configuration via .setup will be removed in future versions of the Component Library gem. Please use .configure instead."
  self.configuration ||= Configuration.new
  yield(configuration)
end

.stylesheet_pathObject



24
25
26
# File 'lib/component_library.rb', line 24

def self.stylesheet_path
  '_component_library/library'
end