MCPcopy Create free account
hub / github.com/Snapchat/Valdi / checkNodeKind

Method checkNodeKind

compiler/companion/src/JSXProcessor.ts:1374–1378  ·  view source on GitHub ↗
(node: ts.Node, expectedKind: ts.SyntaxKind)

Source from the content-addressed store, hash-verified

1372 }
1373
1374 private checkNodeKind(node: ts.Node, expectedKind: ts.SyntaxKind) {
1375 if (node.kind !== expectedKind) {
1376 this.onError(node, `Unexpectedly got node kind ${node.kind} (expected ${expectedKind})`);
1377 }
1378 }
1379
1380 private isExpressionNonStaticMethodDeclaration(expression: ts.Expression, output: JSXOutputState): boolean {
1381 const resolvedType = resolveTypeOfExpression(expression, output.typeChecker);

Callers 1

extractJSXAttributeMethod · 0.95

Calls 1

onErrorMethod · 0.95

Tested by

no test coverage detected