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

Function toRelative

packages/plugin-legacy/src/index.ts:109–110  ·  view source on GitHub ↗
(filename: string, _hostId: string)

Source from the content-addressed store, hash-verified

107): string {
108 const relativeUrlPath = normalizePath(path.relative(config.root, htmlPath))
109 const toRelative = (filename: string, _hostId: string) =>
110 getBaseInHTML(relativeUrlPath, config) + filename
111 return toOutputFilePathInHtml(
112 filename,
113 'asset',

Callers 1

toOutputFilePathInHtmlFunction · 0.70

Calls 1

getBaseInHTMLFunction · 0.70

Tested by

no test coverage detected