MCPcopy Index your code
hub / github.com/coder/coder / getFileContent

Function getFileContent

site/src/utils/filetree.ts:75–77  ·  view source on GitHub ↗
(path: string, fileTree: FileTree)

Source from the content-addressed store, hash-verified

73};
74
75export const getFileContent = (path: string, fileTree: FileTree) => {
76 return get(fileTree, path.split("/")) as string | FileTree;
77};
78
79export const getFileText = (path: string, fileTree: FileTree) => {
80 const content = getFileContent(path, fileTree);

Callers 4

filetree.test.tsFile · 0.90
moveFileFunction · 0.85
getFileTextFunction · 0.85
isFolderFunction · 0.85

Calls 1

getFunction · 0.85

Tested by

no test coverage detected