Method: AssetBox.load!

Defined in:
lib/asset_box.rb

.load!Object



7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# File 'lib/asset_box.rb', line 7

def load!
  register_compass_extension if compass?

  if rails?
    register_rails_engine
  elsif hanami?
    register_hanami
  elsif sprockets?
    register_sprockets
  elsif defined?(::Sass) && ::Sass.respond_to?(:load_paths)
    ::Sass.load_paths << stylesheets_path
  end

  if defined?(::Sass::Script::Value::Number)
    # bootstrap requires minimum precision of 8, see https://github.com/twbs/bootstrap-sass/issues/409
    ::Sass::Script::Value::Number.precision = [8, ::Sass::Script::Value::Number.precision].max
  end
end