Skip to contents

Booleans are represented in Zod schema as either a boolean (z.boolean()), or a typed Uint8Array (z.instanceof(Uint8Array)).

Usage

ts_logical(n = -1L)

Arguments

n

The length of the boolean vector. If n = 1 then a single boolean is expected. If n = 0 then any length is expected. If n > 1 then a boolean vector of length n is expected.

Value

A ts object that accepts logical scalars or vectors of length n.