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

Function getFileUrlFromRelativePath

packages/vite/src/node/build.ts:1576–1577  ·  view source on GitHub ↗
(path: string)

Source from the content-addressed store, hash-verified

1574 `require('u' + 'rl').pathToFileURL(${path}).href`
1575
1576const getFileUrlFromRelativePath = (path: string) =>
1577 getFileUrlFromFullPath(`__dirname + '/${escapeId(path)}'`)
1578
1579const relativeUrlMechanisms: Record<
1580 InternalModuleFormat,

Callers 1

build.tsFile · 0.85

Calls 2

getFileUrlFromFullPathFunction · 0.85
escapeIdFunction · 0.85

Tested by

no test coverage detected