Home > @websublime/schema > ObjectSchemaType

ObjectSchemaType class

Object model type validation

Signature:

export declare class ObjectSchemaType<T> extends BaseSchemaType<T> 

Extends: BaseSchemaType<T>

Constructors

ConstructorModifiersDescription
(constructor)(properties, errorMessage)Create ObjectSchemaType instance.

Properties

PropertyModifiersTypeDescription
propertiesProperties<Omit<T, 'toJSON'>>Properties model types.
typestring

Methods

MethodModifiersDescription
check(value, parent, context, drill)Check if object is valid.
isEmpty(value)Validate if an object is empty
shape(properties)Shape a child object