class Webpacker::Compiler
def watched_files_digest
def watched_files_digest warn "Webpacker::Compiler.watched_paths has been deprecated. Set additional_paths in webpacker.yml instead." unless watched_paths.empty? files = Dir[*default_watched_paths, *watched_paths].reject { |f| File.directory?(f) } file_ids = files.sort.map { |f| "#{File.basename(f)}/#{Digest::SHA1.file(f).hexdigest}" } Digest::SHA1.hexdigest(file_ids.join("/")) end