Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 8 additions & 6 deletions packages/vite/src/shared/hmr.ts
Original file line number Diff line number Diff line change
Expand Up @@ -219,12 +219,14 @@ export class HMRClient {
if (disposer) return disposer(this.dataMap.get(path))
}),
)
paths.forEach((path) => {
const fn = this.pruneMap.get(path)
if (fn) {
fn(this.dataMap.get(path))
}
})
await Promise.all(
paths.map((path) => {
const fn = this.pruneMap.get(path)
if (fn) {
return fn(this.dataMap.get(path))
}
}),
)
}

protected warnFailedUpdate(err: Error, path: string | string[]): void {
Expand Down
Loading