MCPcopy Create free account
hub / github.com/Effect-TS/effect / publicDeclarationRange

Function publicDeclarationRange

packages/tools/jsdocs/src/Jsdocs.ts:2770–2778  ·  view source on GitHub ↗
(node: ts.Node, name: string)

Source from the content-addressed store, hash-verified

2768}
2769
2770function publicDeclarationRange(node: ts.Node, name: string): readonly [number, number] {
2771 if (ts.isVariableStatement(node)) {
2772 const declaration = node.declarationList.declarations.find((item) =>
2773 ts.isIdentifier(item.name) && item.name.text === name
2774 )
2775 if (declaration !== undefined) return nodeRange(declaration)
2776 }
2777 return nodeRange(node)
2778}
2779
2780function bucketOfTs(node: ts.Node): ExportBucket | undefined {
2781 if (ts.isVariableStatement(node) || ts.isFunctionDeclaration(node) || ts.isClassDeclaration(node)) return "value"

Callers 2

parseNamespaceTsFunction · 0.85
parseSourceFileDocsFunction · 0.85

Calls 2

nodeRangeFunction · 0.85
findMethod · 0.45

Tested by

no test coverage detected