idToPathAndNamespace() — vite Function Reference
Architecture documentation for the idToPathAndNamespace() function in pluginConverter.ts from the vite codebase.
Entity Profile
Dependency Diagram
graph TD 1cebaeb4_7ad4_b30a_cf3d_ce32068ff869["idToPathAndNamespace()"] b8dcab0c_e45e_1664_f34c_62cebf0403f4["pluginConverter.ts"] 1cebaeb4_7ad4_b30a_cf3d_ce32068ff869 -->|defined in| b8dcab0c_e45e_1664_f34c_62cebf0403f4 9f6f139c_8c3d_b748_997b_26d6d6e67035["convertEsbuildPluginToRolldownPlugin()"] 9f6f139c_8c3d_b748_997b_26d6d6e67035 -->|calls| 1cebaeb4_7ad4_b30a_cf3d_ce32068ff869 eb06e8c3_f076_d27b_2e82_e6b6e87be239["createResolveIdHandler()"] eb06e8c3_f076_d27b_2e82_e6b6e87be239 -->|calls| 1cebaeb4_7ad4_b30a_cf3d_ce32068ff869 428f2e15_3be7_8055_9526_1da80db25615["createLoadHandler()"] 428f2e15_3be7_8055_9526_1da80db25615 -->|calls| 1cebaeb4_7ad4_b30a_cf3d_ce32068ff869 style 1cebaeb4_7ad4_b30a_cf3d_ce32068ff869 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/vite/src/node/optimizer/pluginConverter.ts lines 300–311
function idToPathAndNamespace(
id: string | undefined,
): [path: string | undefined, namespace: string] {
if (id === undefined) return [undefined, 'file']
const namespaceIndex = id.indexOf(':')
if (namespaceIndex >= 0) {
return [id.slice(namespaceIndex + 1), id.slice(0, namespaceIndex)]
} else {
return [id, 'file']
}
}
Domain
Subdomains
Source
Frequently Asked Questions
What does idToPathAndNamespace() do?
idToPathAndNamespace() is a function in the vite codebase, defined in packages/vite/src/node/optimizer/pluginConverter.ts.
Where is idToPathAndNamespace() defined?
idToPathAndNamespace() is defined in packages/vite/src/node/optimizer/pluginConverter.ts at line 300.
What calls idToPathAndNamespace()?
idToPathAndNamespace() is called by 3 function(s): convertEsbuildPluginToRolldownPlugin, createLoadHandler, createResolveIdHandler.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free