Skip to content

Commit 4d9a94a

Browse files
authored
[fix] allow users to override build target (#2618)
1 parent ae352fc commit 4d9a94a

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

.changeset/unlucky-mugs-dress.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@sveltejs/kit': patch
3+
---
4+
5+
[fix] allow users to override build target

packages/kit/src/core/build/index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -444,6 +444,9 @@ async function build_server(
444444
const vite_config = config.kit.vite();
445445

446446
const default_config = {
447+
build: {
448+
target: 'es2020'
449+
},
447450
server: {
448451
fs: {
449452
strict: true
@@ -460,7 +463,6 @@ async function build_server(
460463
root: cwd,
461464
base: assets_base,
462465
build: {
463-
target: 'es2020',
464466
ssr: true,
465467
outDir: `${output_dir}/server`,
466468
polyfillDynamicImport: false,

0 commit comments

Comments
 (0)