Skip to content

Commit

Permalink
Merge pull request #965 from lucasmazza/lm-sprockets-rails-3
Browse files Browse the repository at this point in the history
Add support for `sprockets-rails` 3 and `sprockets` 4.
  • Loading branch information
glebm committed Sep 27, 2015
2 parents 0c7cec0 + 3e0fafa commit 0399482
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/bootstrap-sass/engine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,12 @@ class Engine < ::Rails::Engine
%w(stylesheets javascripts fonts images).each do |sub|
app.config.assets.paths << root.join('assets', sub).to_s
end
app.config.assets.precompile << %r(bootstrap/glyphicons-halflings-regular\.(?:eot|svg|ttf|woff2?)$)

# sprockets-rails 3 tracks down the calls to `font_path` and `image_path`
# and automatically precompiles the referenced assets.
unless Sprockets::Rails::VERSION.starts_with?('3')
app.config.assets.precompile << %r(bootstrap/glyphicons-halflings-regular\.(?:eot|svg|ttf|woff2?)$)
end
end
end
end
Expand Down

0 comments on commit 0399482

Please sign in to comment.