MCPcopy
hub / github.com/vitejs/vite / slash

Function slash

packages/vite/src/shared/utils.ts:27–29  ·  view source on GitHub ↗
(p: string)

Source from the content-addressed store, hash-verified

25
26const windowsSlashRE = /\\/g
27export function slash(p: string): string {
28 return p.replace(windowsSlashRE, '/')
29}
30
31const postfixRE = /[?#].*$/
32export function cleanUrl(url: string): string {

Callers 15

normalizeModuleIdFunction · 0.90
supportRelativeURLFunction · 0.90
normalizePathFunction · 0.90
injectQueryFunction · 0.90
loadAndTransformFunction · 0.90
checkLoadingAccessFunction · 0.90
getMatcherStringFunction · 0.90
patternToIdFilterFunction · 0.90
transformGlobImportFunction · 0.90
resolveAssetUrlsInCssFunction · 0.90
handlerFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected