From cfef100ed704361d86dcdbaeda76dd8649e321ef Mon Sep 17 00:00:00 2001 From: Sam Date: Mon, 17 Apr 2017 11:04:00 -0400 Subject: [PATCH] FIX: ignore loose .es6 files during precompile also corrects precompile statement to include preload store --- config/application.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config/application.rb b/config/application.rb index 2e82a8ee656..4ef778ab19c 100644 --- a/config/application.rb +++ b/config/application.rb @@ -79,7 +79,7 @@ module Discourse end] config.assets.precompile += %w{ - vendor.js admin.js preload-store.js.es6 + vendor.js admin.js preload-store.js browser-update.js break_string.js ember_jquery.js pretty-text-bundle.js wizard-application.js wizard-vendor.js plugin.js plugin-third-party.js @@ -95,7 +95,7 @@ module Discourse initializer :fix_sprockets_loose_file_searcher, after: :set_default_precompile do |app| app.config.assets.precompile.delete(Sprockets::Railtie::LOOSE_APP_ASSETS) start_path = ::Rails.root.join("app/assets").to_s - exclude = ['.hbs', '.js', '.css', ''] + exclude = ['.es6', '.hbs', '.js', '.css', ''] app.config.assets.precompile << lambda do |logical_path, filename| filename.start_with?(start_path) && !exclude.include?(File.extname(logical_path))