MCPcopy Create free account
hub / github.com/nodejs/node / watchPackageJsonLookupPath

Function watchPackageJsonLookupPath

test/fixtures/snapshot/typescript.js:123867–123872  ·  view source on GitHub ↗
(packageJsonPath)

Source from the content-addressed store, hash-verified

123865 watchFilePath(missingFilePath, missingFilePath, onMissingFileChange, ts.PollingInterval.Medium, watchOptions, ts.WatchType.MissingFile);
123866 }
123867 function watchPackageJsonLookupPath(packageJsonPath) {
123868 // If the package.json is pulled into the compilation itself (eg, via json imports), don't add a second watcher here
123869 return sourceFilesCache.has(packageJsonPath) ?
123870 ts.noopFileWatcher :
123871 watchFilePath(packageJsonPath, packageJsonPath, onPackageJsonChange, ts.PollingInterval.High, watchOptions, ts.WatchType.PackageJson);
123872 }
123873 function onPackageJsonChange(fileName, eventKind, path) {
123874 updateCachedSystemWithFile(fileName, path, eventKind);
123875 // package.json changes invalidate module resolution and can change the set of loaded files

Callers

nothing calls this directly

Calls 2

watchFilePathFunction · 0.85
hasMethod · 0.65

Tested by

no test coverage detected