CodeQL library for JavaScript/TypeScript
codeql/javascript-all 2.10.3 (changelog, source)
Search

Member predicate ExprNameBindingNode::getClassNode

Gets the class, or function acting as a class, referenced by this name.

class Foo {}
const T = Foo;
var x = T; // getClassNode() maps T to the class Foo above

function Bar() {}
Bar.prototype.blah = function() {};
const S = Bar;
var x = S; // getClassNode() maps S to the function Bar above
ClassNode getClassNode()