Skip to content

Commit

Permalink
chore: update deprecation warnings for improved migration DX (#8866)
Browse files Browse the repository at this point in the history
  • Loading branch information
brillout committed Jun 30, 2022
1 parent 026eb18 commit 4eb2348
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/vite/src/node/config.ts
Expand Up @@ -636,14 +636,16 @@ export async function resolveConfig(
if (middlewareMode === 'ssr') {
logger.warn(
colors.yellow(
`server.middlewareMode 'ssr' is now deprecated, use server.middlewareMode true and appType 'custom'`
`Setting server.middlewareMode to 'ssr' is deprecated, set server.middlewareMode to \`true\`${
config.appType === 'custom' ? '' : ` and appType to 'custom'`
} instead`
)
)
}
if (middlewareMode === 'html') {
logger.warn(
colors.yellow(
`server.middlewareMode 'html' is now deprecated, use server.middlewareMode true`
`Setting server.middlewareMode to 'html' is deprecated, set server.middlewareMode to \`true\` instead`
)
)
}
Expand Down

0 comments on commit 4eb2348

Please sign in to comment.