From 07e57823e8228a65a591bd51db5ecfc3cf5f06fa Mon Sep 17 00:00:00 2001 From: tekniklr Date: Sun, 15 Sep 2024 14:09:08 -0700 Subject: [PATCH] switch from uglifier to terser --- Gemfile | 3 +-- Gemfile.lock | 11 +++-------- config/environments/production.rb | 2 +- 3 files changed, 5 insertions(+), 11 deletions(-) diff --git a/Gemfile b/Gemfile index 3b46e97..ac15e4c 100644 --- a/Gemfile +++ b/Gemfile @@ -6,7 +6,6 @@ gem 'puma' gem 'haml' gem 'sassc-rails' -gem 'uglifier' gem "sprockets-rails" gem 'jquery-rails' @@ -41,7 +40,7 @@ end group :production do gem 'exception_notification' - gem 'mini_racer' + gem 'terser' end group :development do diff --git a/Gemfile.lock b/Gemfile.lock index bcc0378..42afa95 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -202,8 +202,6 @@ GEM lastfm (1.27.4) httparty xml-simple - libv8-node (22.7.0.4-x86_64-darwin) - libv8-node (22.7.0.4-x86_64-linux) logger (1.6.1) loofah (2.22.0) crass (~> 1.0.2) @@ -219,8 +217,6 @@ GEM mime-types-data (~> 3.2015) mime-types-data (3.2024.0903) mini_mime (1.1.5) - mini_racer (0.15.0) - libv8-node (~> 22.7.0.1) minitest (5.25.1) multi_xml (0.7.1) bigdecimal (~> 3.1) @@ -367,14 +363,14 @@ GEM temple (0.10.3) terrapin (1.0.1) climate_control + terser (1.2.3) + execjs (>= 0.3.0, < 3) thor (1.3.2) tilt (2.4.0) timeliness (0.4.5) timeout (0.4.1) tzinfo (2.0.6) concurrent-ruby (~> 1.0) - uglifier (4.2.0) - execjs (>= 0.3.0, < 3) uri (0.13.1) useragent (0.16.10) validates_timeliness (7.0.0.beta2) @@ -414,7 +410,6 @@ DEPENDENCIES kt-paperclip lastfm mastodon-api! - mini_racer minitest mysql2 net-pop! @@ -429,7 +424,7 @@ DEPENDENCIES sassc-rails shoulda sprockets-rails - uglifier + terser validates_timeliness (>= 7.0.0.beta1) BUNDLED WITH diff --git a/config/environments/production.rb b/config/environments/production.rb index bcc3aa1..1fde0b2 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -25,7 +25,7 @@ config.assets.digest = true # Compress both stylesheets and JavaScripts - config.assets.js_compressor = Uglifier.new(harmony: true) + config.assets.js_compressor = :terser # Specifies the header that your server uses for sending files # (comment out if your front-end server doesn't support this)