From a46d3162ae5743a8af783bd0ffdbd022476859be Mon Sep 17 00:00:00 2001 From: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> Date: Fri, 12 May 2023 07:27:25 -0700 Subject: Fix importstar_ts/ReExportTypeOnlyFileES6 --- src/bundler/bundle_v2.zig | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/bundler/bundle_v2.zig b/src/bundler/bundle_v2.zig index 87cb1154f..94c8df6c4 100644 --- a/src/bundler/bundle_v2.zig +++ b/src/bundler/bundle_v2.zig @@ -2137,6 +2137,10 @@ pub const BundleV2 = struct { new_input_file.source.index = Index.source(graph.input_files.len); new_input_file.source.path = new_task.path; new_input_file.source.key_path = new_input_file.source.path; + + // We need to ensure the loader is set or else importstar_ts/ReExportTypeOnlyFileES6 will fail. + new_input_file.loader = loader; + existing.value_ptr.* = new_input_file.source.index.get(); new_task.source_index = new_input_file.source.index; -- cgit v1.2.3