Interface BothPropertiesSchema<P, O>

a schema for an object with required and optional properties

interface BothPropertiesSchema<P, O> {
    additionalProperties?: boolean;
    metadata?: unknown;
    nullable?: boolean;
    optionalProperties: O;
    properties: P;
}

Type Parameters

Properties

additionalProperties?: boolean

if non-listed properties are allowed

metadata?: unknown

optional metadata on a schema

nullable?: boolean

a key indicating if a type can be null

optionalProperties: O

a schema for every optional property

properties: P

a schema for every required property