ts-api-utils - v3.0.0-rc.1
    Preparing search index...

    Function isUnionOrIntersectionTypeNode

    • Test if a node is an UnionOrIntersectionTypeNode.

      Parameters

      • node: Node

      Returns node is UnionOrIntersectionTypeNode

      Whether the given node appears to be an UnionOrIntersectionTypeNode.

      declare const node: ts.Node;

      if (isUnionOrIntersectionTypeNode(node)) {
      // ...
      }