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

Function getFileAndTextSpanFromNode

test/fixtures/snapshot/typescript.js:137110–137116  ·  view source on GitHub ↗
(node)

Source from the content-addressed store, hash-verified

137108 return __assign({ containerKind: "" /* ScriptElementKind.unknown */, containerName: "", fileName: sourceFile.fileName, kind: kind, name: name, textSpan: textSpan, displayParts: displayParts }, toContextSpan(textSpan, sourceFile, context));
137109 }
137110 function getFileAndTextSpanFromNode(node) {
137111 var sourceFile = node.getSourceFile();
137112 return {
137113 sourceFile: sourceFile,
137114 textSpan: getTextSpan(ts.isComputedPropertyName(node) ? node.expression : node, sourceFile)
137115 };
137116 }
137117 function getDefinitionKindAndDisplayParts(symbol, checker, node) {
137118 var meaning = Core.getIntersectingMeaningFromDeclarations(node, symbol);
137119 var enclosingDeclaration = symbol.declarations && ts.firstOrUndefined(symbol.declarations) || node;

Calls 1

getTextSpanFunction · 0.85

Tested by

no test coverage detected