Module

x/ts_morph/mod.ts>Node#getPreviousSibling

TypeScript Compiler API wrapper for static analysis and programmatic code changes.
Very Popular
Latest
method Node.prototype.getPreviousSibling
import { Node } from "https://dotland.deno.dev/x/ts_morph@22.0.0/mod.ts";

Gets the previous sibling.

Parameters

optional
condition: (node: Node) => node is T
  • Optional condition for getting the previous sibling.

Returns

T | undefined

Gets the previous sibling.

Parameters

optional
condition: (node: Node) => boolean
  • Optional condition for getting the previous sibling.

Returns

Node | undefined