Skip to content

Instantly share code, notes, and snippets.

@paul-at
Created October 24, 2018 10:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save paul-at/757f2f17c6c8867ce6b3bcfd00f95907 to your computer and use it in GitHub Desktop.
Save paul-at/757f2f17c6c8867ce6b3bcfd00f95907 to your computer and use it in GitHub Desktop.
Check for Uglifier-incompatible ES6 files
require 'uglifier'
JS_PATH = ".../app/assets/javascripts/**/*.js";
Dir[JS_PATH].each do |file_name|
puts "\n#{file_name}"
puts Uglifier.compile(File.read(file_name))
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment