Make Asset Compression On Production Work With Angular Js

Posted by Weston Ganger

For AngularJS and likely others too, the javascript minification changes variable names to short names. This must be changed although it will make your minification slightly less minified, its the way it must be done so that it works on production.

Edit your config/environments/production.rb

The old Rails 3 way of doing it was:

config.assets.js_compressor = { => false) 

The new Rails 4 way:

config.assets.js_compressor = => false)

Article Topic:Software Development - Rails

Date:July 15, 2014

Recommended Posts



Send Me A Message

I would love to get in touch and talk about your next project. Feel free to send a message and I will get back to you shortly.

Get Connected