From e156fbc5f6d1e052b4a3975d8234d76a43dea256 Mon Sep 17 00:00:00 2001 From: PJ Date: Mon, 1 Jun 2026 21:04:17 +0530 Subject: [PATCH] refactor(bundler): reuse registration trailer in web bundler --- internal/bundler/web_bundle.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/internal/bundler/web_bundle.go b/internal/bundler/web_bundle.go index af92d3c..ff4584a 100644 --- a/internal/bundler/web_bundle.go +++ b/internal/bundler/web_bundle.go @@ -50,9 +50,7 @@ func BundleWeb(options WebOptions) (Result, error) { defines["process.env."+key] = quoteJSString(value) } - stdinContents := fmt.Sprintf(`import %q; -import %q; -`, runtimeAbs, specAbs) + stdinContents := fmt.Sprintf("import %q;\n%s", runtimeAbs, registrationEntry(specAbs)) output := esbuild.Build(esbuild.BuildOptions{ Stdin: &esbuild.StdinOptions{