Skip to content

Commit

Permalink
fix(start): decouple deployment static option from the deployment preset
Browse files Browse the repository at this point in the history
  • Loading branch information
SeanCassiere committed Sep 19, 2024
1 parent 230c460 commit d8efdd5
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions packages/start/src/config/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,13 +94,6 @@ const testedDeploymentPresets: Array<DeploymentPreset> = [
'cloudflare-pages',
'node-server',
]
const staticDeploymentPresets: Array<DeploymentPreset> = [
'cloudflare-pages-static',
'netlify-static',
'static',
'vercel-static',
'zeabur-static',
]

function checkDeploymentPresetInput(preset: string): DeploymentPreset {
if (!vinxiDeploymentPresets.includes(preset as any)) {
Expand Down Expand Up @@ -223,9 +216,6 @@ export function defineConfig(
const deploymentPreset = checkDeploymentPresetInput(
configDeploymentPreset || 'vercel',
)
const isStaticDeployment =
deploymentOptions.static ??
staticDeploymentPresets.includes(deploymentPreset)

const tsrConfig = getConfig(setTsrDefaults(opts.tsr))

Expand All @@ -242,7 +232,7 @@ export function defineConfig(
return createApp({
server: {
...deploymentOptions,
static: isStaticDeployment,
static: deploymentOptions.static,
preset: deploymentPreset,
experimental: {
asyncContext: true,
Expand Down

0 comments on commit d8efdd5

Please sign in to comment.