MCPcopy Index your code
hub / github.com/nodejs/node / findPackageJsons

Function findPackageJsons

test/fixtures/snapshot/typescript.js:129152–129164  ·  view source on GitHub ↗
(startDirectory, host, stopDirectory)

Source from the content-addressed store, hash-verified

129150 }
129151 ts.tryIOAndConsumeErrors = tryIOAndConsumeErrors;
129152 function findPackageJsons(startDirectory, host, stopDirectory) {
129153 var paths = [];
129154 ts.forEachAncestorDirectory(startDirectory, function (ancestor) {
129155 if (ancestor === stopDirectory) {
129156 return true;
129157 }
129158 var currentConfigPath = ts.combinePaths(ancestor, "package.json");
129159 if (tryFileExists(host, currentConfigPath)) {
129160 paths.push(currentConfigPath);
129161 }
129162 });
129163 return paths;
129164 }
129165 ts.findPackageJsons = findPackageJsons;
129166 function findPackageJson(directory, host) {
129167 var packageJson;

Callers

nothing calls this directly

Calls 2

tryFileExistsFunction · 0.85
pushMethod · 0.45

Tested by

no test coverage detected