diff --git a/src/utils.tsx b/src/utils.tsx index 0b1b307..3fb3dc1 100644 --- a/src/utils.tsx +++ b/src/utils.tsx @@ -146,7 +146,9 @@ export async function transpile(path: string): Promise { const { mtime } = await stat(path) const key = `${path}?${mtime}` - let cached = transpileCache[key] + // no caching in dev mode + let cached = process.env.NODE_ENV === 'production' ? transpileCache[key] : undefined + if (!cached) { const result = await Bun.build({ entrypoints: [path],