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

Function isApplicableVersionedTypesKey

test/fixtures/snapshot/typescript.js:44282–44291  ·  view source on GitHub ↗
(conditions, key)

Source from the content-addressed store, hash-verified

44280 }
44281 /* @internal */
44282 function isApplicableVersionedTypesKey(conditions, key) {
44283 if (conditions.indexOf("types") === -1)
44284 return false; // only apply versioned types conditions if the types condition is applied
44285 if (!ts.startsWith(key, "types@"))
44286 return false;
44287 var range = ts.VersionRange.tryParse(key.substring("types@".length));
44288 if (!range)
44289 return false;
44290 return range.test(ts.version);
44291 }
44292 ts.isApplicableVersionedTypesKey = isApplicableVersionedTypesKey;
44293 function loadModuleFromNearestNodeModulesDirectory(extensions, moduleName, directory, state, cache, redirectedReference) {
44294 return loadModuleFromNearestNodeModulesDirectoryWorker(extensions, moduleName, directory, state, /*typesScopeOnly*/ false, cache, redirectedReference);

Calls 2

indexOfMethod · 0.45
testMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…