From 943b91d51e0a700a4176bfa6335e15665f2bb668 Mon Sep 17 00:00:00 2001 From: saberzero1 Date: Sat, 14 Feb 2026 01:11:52 +0100 Subject: [PATCH] fix: standardize inline script transpilation in tsup config Use stdin-based esbuild.build with proper TS transpilation, minification, and ESM output format matching v5's proven inline-script-loader pattern. --- tsup.config.ts | 99 ++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 75 insertions(+), 24 deletions(-) diff --git a/tsup.config.ts b/tsup.config.ts index 7349bdb..932f02b 100644 --- a/tsup.config.ts +++ b/tsup.config.ts @@ -1,4 +1,78 @@ import { defineConfig } from "tsup"; +import type { Plugin } from "esbuild"; +import path from "path"; + +/** + * Esbuild plugin that bundles `.inline.ts` files into browser-ready JavaScript strings. + * + * Problem: Inline scripts are embedded as raw text into `