MCPcopy
hub / github.com/vitest-dev/vitest / cleanUrl

Function cleanUrl

packages/utils/src/helpers.ts:64–66  ·  view source on GitHub ↗
(url: string)

Source from the content-addressed store, hash-verified

62
63const postfixRE = /[?#].*$/
64export function cleanUrl(url: string): string {
65 return url.replace(postfixRE, '')
66}
67
68export function splitFileAndPostfix(path: string): {
69 file: string

Callers 12

loadAutomockMethod · 0.90
loadManualMockMethod · 0.90
injectQueryFunction · 0.90
createLoadHookFunction · 0.90
isValidNodeImportFunction · 0.90
isIncludedMethod · 0.90
fsPathFromUrlFunction · 0.90
normalizeResolvedIdToUrlFunction · 0.90
resolveFunction · 0.90
transformFunction · 0.90
splitFileAndPostfixFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected