Skip to content

Commit

Permalink
fix: allow overwrite esbuild config
Browse files Browse the repository at this point in the history
  • Loading branch information
sxzz committed Nov 26, 2024
1 parent 64f2256 commit f9c4ff9
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/core/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -251,8 +251,11 @@ export async function transformMain(
resolvedCode,
filename,
{
loader: 'ts',
target: pluginContext.framework === 'vite' ? 'esnext' : undefined,
// #430 support decorators in .vue file
// target can be overridden by esbuild config target
...options.devServer?.config.esbuild,
loader: 'ts',
sourcemap: options.sourceMap,
},
resolvedMap,
Expand Down

0 comments on commit f9c4ff9

Please sign in to comment.