Skip to content

Commit

Permalink
fix(ssr): show ssr module loader error stack
Browse files Browse the repository at this point in the history
  • Loading branch information
sun0day committed Mar 29, 2023
1 parent 9697e64 commit 90342d3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/vite/src/node/ssr/ssrModuleLoader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,8 @@ async function instantiateModule(
server.config.logger.error(
colors.red(
`Error when evaluating SSR module ${url}:` +
(e.importee ? ` failed to import "${e.importee}"\n` : '\n'),
(e.importee ? ` failed to import "${e.importee}"` : '') +
`\n|- ${e.stack}\n`,
),
{
timestamp: true,
Expand Down

0 comments on commit 90342d3

Please sign in to comment.