lib/tasks/assets.rake in react_on_rails-12.0.3 vs lib/tasks/assets.rake in react_on_rails-12.0.4

- old
+ new

@@ -18,12 +18,12 @@ puts "Invoking task webpacker:clean from React on Rails" # VERSIONS is per the rails/webpacker clean method definition. # We set it very big so that it is not used, and then clean just # removes files older than 1 hour. - VERSIONS = 100_000 - Rake::Task["webpacker:clean"].invoke(VERSIONS) + versions = 100_000 + Rake::Task["webpacker:clean"].invoke(versions) } if Rake::Task.task_defined?("assets:precompile") Rake::Task["assets:precompile"].enhance do precompile_tasks.call @@ -38,13 +38,13 @@ # Sprockets independent tasks # rubocop:disable Metrics/BlockLength namespace :react_on_rails do namespace :assets do desc <<-DESC.strip_heredoc - Compile assets with webpack - Uses command defined with ReactOnRails.configuration.build_production_command - sh "#{ReactOnRails::Utils.prepend_cd_node_modules_directory('<ReactOnRails.configuration.build_production_command>')}" - Note: This command is not automatically added to assets:precompile if the rails/webpacker + Compile assets with webpack + Uses command defined with ReactOnRails.configuration.build_production_command + sh "#{ReactOnRails::Utils.prepend_cd_node_modules_directory('<ReactOnRails.configuration.build_production_command>')}" + Note: This command is not automatically added to assets:precompile if the rails/webpacker configuration file config/webpack/production.js exists. DESC task webpack: :locale do if ReactOnRails.configuration.build_production_command.present? sh ReactOnRails::Utils.prepend_cd_node_modules_directory(