Skip to content

Commit

Permalink
fix: tolerate undefined manifest[src]
Browse files Browse the repository at this point in the history
  • Loading branch information
brillout committed Feb 8, 2024
1 parent 069e996 commit a79c894
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vite/src/node/plugins/manifest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ export function manifestPlugin(config: ResolvedConfig): Plugin {

// If JS chunk and asset chunk are both generated from the same source file,
// prioritize JS chunk as it contains more information
const { file } = manifest[src]
const file = manifest[src]?.file || ''
if (
file.endsWith('.js') ||
file.endsWith('.mjs') ||
Expand Down

0 comments on commit a79c894

Please sign in to comment.