Skip to content

Instantly share code, notes, and snippets.

View JohannesFischer's full-sized avatar

Johannes Fischer JohannesFischer

View GitHub Profile
@JohannesFischer
JohannesFischer / compression.rb
Last active June 11, 2016 21:15 — forked from remino/compression.rb
Ruby on Rails: Minify HTML, CSS, & JS
# config/initializers/compression.rb
Rails.application.configure do
# Use environment names or environment variables:
# break unless Rails.env.production?
break unless ENV['ENABLE_COMPRESSION'] == '1'
# Strip all comments from JavaScript files, even copyright notices.
# By doing so, you are legally required to acknowledge
# the use of the software somewhere in your Web site or app: