build: set esbuildOptions outbase to 'src' in tsup config

Set `options.outbase = 'src'` in the esbuildOptions callback to ensure
output files preserve the correct directory structure relative to the
`src` folder, preventing path flattening during the build process.
This commit is contained in:
2026-04-14 20:15:30 -04:00
parent 240bfd1ff1
commit 6cd6ce6f6f
+1
View File
@@ -78,6 +78,7 @@ export default defineConfig([
], ],
bundle: false, // Don't bundle these files bundle: false, // Don't bundle these files
esbuildOptions(options) { esbuildOptions(options) {
options.outbase = 'src';
options.loader = { options.loader = {
'.js': 'jsx', '.js': 'jsx',
'.jsx': 'jsx', '.jsx': 'jsx',