Skip to content

Commit

Permalink
fix(utils): add dot-all flag to match all characters, fix #3761 (#3780)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sociosarbis committed Jul 7, 2021
1 parent 5dd670f commit b9cdfbe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/vite/src/node/utils.ts
Expand Up @@ -94,8 +94,8 @@ export function ensureVolumeInPath(file: string): string {
return isWindows ? path.resolve(file) : file
}

export const queryRE = /\?.*$/
export const hashRE = /#.*$/
export const queryRE = /\?.*$/s
export const hashRE = /#.*$/s

export const cleanUrl = (url: string): string =>
url.replace(hashRE, '').replace(queryRE, '')
Expand Down

0 comments on commit b9cdfbe

Please sign in to comment.