method Node.prototype.getParentIfimport { Node } from "https://deno.land/x/ts_morph@22.0.0/mod.ts"; getParentIf<T extends Node>(condition: (parent: Node | undefined, node: Node) => parent is T): T | undefinedGets the parent if it matches a certain condition. getParentIf(condition: (parent: Node | undefined, node: Node) => boolean): Node | undefinedGets the parent if it matches a certain condition. Gets the parent if it matches a certain condition. Type ParametersT extends NodeParameterscondition: (parent: Node | undefined, node: Node) => parent is TReturnsT | undefinedGets the parent if it matches a certain condition. Parameterscondition: (parent: Node | undefined, node: Node) => booleanReturnsNode | undefined