Options
All
  • Public
  • Public/Protected
  • All
Menu

Represents a type predicate.

function isString(anything: any): anything is string {}
function assert(condition: boolean): asserts condition {}

Hierarchy

Index

Constructors

Properties

asserts: boolean

True if the type is of the form asserts val is string, false if the type is of the form val is string

name: string

The identifier name which is tested by the predicate.

targetType?: Type

The type that the identifier is tested to be. May be undefined if the type is of the form asserts val. Will be defined if the type is of the form asserts val is string or val is string.

type: "predicate" = "predicate"

The type name identifier.

Methods

  • toString(): string

Generated using TypeDoc