Skip to main content
Module

x/ts_morph/mod.ts>Node#getParentOrThrow

TypeScript Compiler API wrapper for static analysis and programmatic code changes.
Very Popular
Go to Latest
method Node.prototype.getParentOrThrow
import { Node } from "https://deno.land/x/ts_morph@18.0.0/mod.ts";

Gets the parent or throws an error if it doesn't exist.

Parameters

optional
message: string | (() => string)

Returns

Node<ts.Node>