diff --git a/Gemfile b/Gemfile index 6f53f302..be71d104 100644 --- a/Gemfile +++ b/Gemfile @@ -22,7 +22,7 @@ gem 'redis', '~> 4.8', require: %w[redis redis/connection/hiredis] gem 'redis-namespace' gem 'rubyzip', require: 'zip' gem 'sassc-rails' -gem 'uglifier' +gem 'terser' # Temporarily fix for ruby 3.1 gem 'net-imap', require: false diff --git a/Gemfile.lock b/Gemfile.lock index 1c9d98d2..4315be8c 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -353,6 +353,8 @@ GEM sshkit (1.21.5) net-scp (>= 1.1.2) net-ssh (>= 2.8.0) + terser (1.1.18) + execjs (>= 0.3.0, < 3) thor (1.2.2) tilt (2.2.0) timeout (0.4.0) @@ -362,8 +364,6 @@ GEM railties (>= 6.0.0) tzinfo (2.0.6) concurrent-ruby (~> 1.0) - uglifier (4.2.0) - execjs (>= 0.3.0, < 3) unicode-display_width (2.4.2) uniform_notifier (1.16.0) websocket (1.2.9) @@ -425,8 +425,8 @@ DEPENDENCIES sassc-rails selenium-webdriver spring + terser tzinfo-data - uglifier RUBY VERSION ruby 3.1.2p20 diff --git a/config/environments/production.rb b/config/environments/production.rb index de4eb364..7aceefff 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -26,7 +26,7 @@ # Compress CSS using a preprocessor. # config.assets.css_compressor = :sass - config.assets.js_compressor = Uglifier.new harmony: true + config.assets.js_compressor = :terser # Do not fallback to assets pipeline if a precompiled asset is missed. config.assets.compile = false