Skip to content

Commit

Permalink
fix: change the preview default mode from development to `productio…
Browse files Browse the repository at this point in the history
…n` (#4483)
  • Loading branch information
ygj6 committed Aug 4, 2021
1 parent e793a91 commit 77933ba
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/vite/src/node/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ cli
}
},
'serve',
'development'
'production'
)
await preview(config, cleanOptions(options))
} catch (e) {
Expand Down
2 changes: 1 addition & 1 deletion packages/vite/src/node/preview.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export async function preview(
config.base,
sirv(distDir, {
etag: true,
dev: !config.isProduction,
dev: true,
single: true
})
)
Expand Down

0 comments on commit 77933ba

Please sign in to comment.