Class UnionType

Represents an union type.

let value: string | string[];

Hierarchy (view full)

Constructors

Properties

type = "union"

The type name identifier.

types: Models.SomeType[]
elementSummaries?: Models.CommentDisplayPart[][]

If present, there should be as many items in this array as there are items in the types array.

This member is only valid on unions which are on DeclarationReflection.type with a ReflectionKind kind of TypeAlias. Specifying it on any other union is undefined behavior.

Methods

  • Implementation method for toString. needsParenthesis will be used to determine if the returned string should be wrapped in parenthesis.

    Returns string