Hello I recently push an update up to Heroku and all of a sudden Active Admin won't precompile. Giving me this error.
Running: rake assets:precompile
rake aborted!
SyntaxError: cannot return a value from a constructor: "this" in class DropdownMenu
(in /tmp/build_etr05wkfpnxp/vendor/bundle/ruby/1.9.1/gems/activeadmin-0.5.1/app/assets/javascripts/active_admin/components/jquery.aa.dropdown-menu.js.cof
fee)
/tmp/build_etr05wkfpnxp/vendor/bundle/ruby/1.9.1/gems/execjs-
1.4.0/lib/execjs/external_runtime.rb:66:in `extract_result'
No clue what happened or how to fix it. It work perfectly fine on my localhost, only happens when I push to heroku. It also worked fine on Heroku before, all I did was add a model to it.
Any ideas?
Thanks!
FIX
https://github.com/gregbell/active_admin/issues/1939
Fix can be found here
https://github.com/gregbell/active_admin/issues/1939
in Gemfile add the coffee-script-source line.
group :assets do
gem 'sass-rails'
gem 'coffee-rails'
gem 'coffee-script-source', '~> 1.4.0' # ADD THIS LINE, 1.5.0 doesn't compile ActiveAdmin JavaScript files
gem 'uglifier'
end
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With