Skip to content

Commit

Permalink
chore: Use interpolation, and run prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
ElMassimo committed Jul 28, 2021
1 parent 5a13c73 commit 1f7f2f3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/vite/src/client/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,9 @@ async function handleMessage(payload: HMRPayload) {
) as HTMLLinkElement[]
).find((e) => e.href.includes(path))
if (el) {
const newPath =
base +
`${path.slice(1)}${path.includes('?') ? '&' : '?'}t=${timestamp}`
const newPath = `${base}${path.slice(1)}${
path.includes('?') ? '&' : '?'
}t=${timestamp}`
el.href = new URL(newPath, el.href).href
}
console.log(`[vite] css hot updated: ${path}`)
Expand Down

0 comments on commit 1f7f2f3

Please sign in to comment.