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

Function getModuleNames

test/fixtures/snapshot/typescript.js:119514–119525  ·  view source on GitHub ↗
(_a)

Source from the content-addressed store, hash-verified

119512 }
119513 ts.getResolutionDiagnostic = getResolutionDiagnostic;
119514 function getModuleNames(_a) {
119515 var imports = _a.imports, moduleAugmentations = _a.moduleAugmentations;
119516 var res = imports.map(function (i) { return i.text; });
119517 for (var _i = 0, moduleAugmentations_1 = moduleAugmentations; _i < moduleAugmentations_1.length; _i++) {
119518 var aug = moduleAugmentations_1[_i];
119519 if (aug.kind === 10 /* SyntaxKind.StringLiteral */) {
119520 res.push(aug.text);
119521 }
119522 // Do nothing if it's an Identifier; we don't need to do module resolution for `declare global`.
119523 }
119524 return res;
119525 }
119526 /* @internal */
119527 function getModuleNameStringLiteralAt(_a, index) {
119528 var imports = _a.imports, moduleAugmentations = _a.moduleAugmentations;

Callers 2

processImportedModulesFunction · 0.85

Calls 2

mapMethod · 0.65
pushMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…