Relative Content

Tag Archive for ruby-on-railsvue.jswebpackershakapacker

CoffeeScriptError: error: reserved word ‘var’ in Rails and Webpacker

I am trying to upgrade my legacy Rails application that uses Webpacker from version 5 to version 6 (v6.0.0.rc.6) following these instructions. The goal is to move away from Webpacker to Shakapacker because Webpacker was retired 2 years ago.
Most of the changes I have made so far are in the Webpacker config files (see below). Now I am stuck with CoffeeScript files, which could not be converted correctly as far as I know. This is the error after running rake assets:precompile: