ExecJS::ProgramError: Unexpected token punc «(», expected punc «:» when running rake assets:precompile on production

后端 未结 10 1434
小鲜肉
小鲜肉 2020-11-28 20:08

When deploying my Rails app I get the following error:

rake aborted!
   ExecJS::ProgramError: Unexpected token punc «(», expected punc «:» (line: 15, col: 14         


        
10条回答
  •  北荒
    北荒 (楼主)
    2020-11-28 20:52

    Update uglifier gem to last version and update your production.rb

    config.assets.js_compressor = Uglifier.new(harmony: true)
    

提交回复
热议问题