mirror of
https://github.com/discourse/discourse.git
synced 2025-05-21 18:12:32 +08:00
DEV: Correctly identify Embroider chunks (#23488)
This method is used by assets:precompile to decide whether to apply `terser` to a file. Embroider chunks do not necessarily start with `chunk.`, and so they were incorrectly being re-terser'd by our assets:precompile task. This is inefficient, and also led to broken sourcemaps on some assets.
This commit is contained in:
@ -64,7 +64,7 @@ module EmberCli
|
||||
end
|
||||
|
||||
def self.is_ember_cli_asset?(name)
|
||||
assets.include?(name) || name.start_with?("chunk.")
|
||||
assets.include?(name) || script_chunks.values.flatten.include?(name.delete_suffix(".js"))
|
||||
end
|
||||
|
||||
def self.ember_version
|
||||
|
Reference in New Issue
Block a user