Skip to content

Instantly share code, notes, and snippets.

@ismarsantos
Created September 13, 2017 14:23
Show Gist options
  • Save ismarsantos/24c726cbfcba7c5596fdee4bea6734e8 to your computer and use it in GitHub Desktop.
Save ismarsantos/24c726cbfcba7c5596fdee4bea6734e8 to your computer and use it in GitHub Desktop.
ExecJS::ProgramError: Unexpected token running rake assets:precompile on production
A more universal way to find the problem in js-assets: Run rails console and:
JS_PATH = "app/assets/javascripts/**/*.js";
Dir[JS_PATH].each do |file_name|
puts "\n#{file_name}"
puts Uglifier.compile(File.read(file_name))
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment