MCPcopy Create free account
hub / github.com/CoderLine/alphaTab / findNode

Function findNode

packages/transpiler/src/BuilderHelpers.ts:42–55  ·  view source on GitHub ↗
(node: ts.Node, kind: ts.SyntaxKind)

Source from the content-addressed store, hash-verified

40}
41
42function findNode(node: ts.Node, kind: ts.SyntaxKind): ts.Node | null {
43 if (node.kind === kind) {
44 return node;
45 }
46
47 for (const c of node.getChildren()) {
48 const f = findNode(c, kind);
49 if (f) {
50 return f;
51 }
52 }
53
54 return null;
55}
56
57export function unwrapArrayItemType(type: ts.Type, typeChecker: ts.TypeChecker): ts.Type | null {
58 if (type.symbol && type.symbol.name === 'Array') {

Callers 1

createNodeFromSourceFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected