BlockSuite API Documentation / @blocksuite/store / BlockSchema
Variable: BlockSchema
const
BlockSchema:ZodObject
<Object
,"strip"
,ZodTypeAny
,Object
,Object
>
Type declaration
model
model:
ZodObject
<Object
,"strip"
,ZodTypeAny
,Object
,Object
>
Type declaration
children
children:
ZodOptional
<ZodArray
<ZodString
,"many"
>> =ContentSchema
flavour
flavour:
ZodString
=FlavourSchema
parent
parent:
ZodOptional
<ZodArray
<ZodString
,"many"
>> =ParentSchema
props
props:
ZodOptional
<ZodFunction
<ZodTuple
<[ZodType
<InternalPrimitives
,ZodTypeDef
,InternalPrimitives
>],ZodUnknown
>,ZodRecord
<ZodString
,ZodAny
>>>
role
role:
ZodEnum
<["root"
,"hub"
,"content"
]> =RoleSchema
toModel
toModel:
ZodOptional
<ZodFunction
<ZodTuple
<[],ZodUnknown
>,ZodType
<BlockModel
<object
>,ZodTypeDef
,BlockModel
<object
>>>>
onUpgrade
onUpgrade:
ZodOptional
<ZodFunction
<ZodTuple
<[ZodAny
,ZodNumber
,ZodNumber
],ZodUnknown
>,ZodVoid
>>
transformer
transformer:
ZodOptional
<ZodFunction
<ZodTuple
<[],ZodUnknown
>,ZodType
<BaseBlockTransformer
<object
>,ZodTypeDef
,BaseBlockTransformer
<object
>>>>
version
version:
ZodNumber
Source
packages/framework/store/src/schema/base.ts:29
Generated using TypeDoc and typedoc-plugin-markdown.