ColDefFn
ColDefFn<
TColumnType> = {():object; <TEncoded,TDecoded,TNullable,TDefault,TPrimaryKey>(args):object; }
Defined in: packages/@livestore/common/dist/schema/state/sqlite/db-schema/dsl/field-defs.d.ts:24
Type Parameters
Section titled “Type Parameters”TColumnType
Section titled “TColumnType”TColumnType extends FieldColumnType
Call Signature
Section titled “Call Signature”():
object
Returns
Section titled “Returns”object
columnType
Section titled “columnType”columnType:
TColumnType
default
Section titled “default”default:
Option.None<never>
nullable
Section titled “nullable”nullable:
false
primaryKey
Section titled “primaryKey”primaryKey:
false
schema
Section titled “schema”schema:
Schema<DefaultEncodedForColumnType<TColumnType>>
Call Signature
Section titled “Call Signature”<
TEncoded,TDecoded,TNullable,TDefault,TPrimaryKey>(args):object
Type Parameters
Section titled “Type Parameters”TEncoded
Section titled “TEncoded”TEncoded extends string | number | Uint8Array<ArrayBufferLike>
TDecoded
Section titled “TDecoded”TDecoded = DefaultEncodedForColumnType<TColumnType>
TNullable
Section titled “TNullable”TNullable extends boolean = false
TDefault
Section titled “TDefault”TDefault = typeof NoDefault
TPrimaryKey
Section titled “TPrimaryKey”TPrimaryKey extends boolean = false
Parameters
Section titled “Parameters”default?
Section titled “default?”TDefault
nullable?
Section titled “nullable?”TNullable
primaryKey?
Section titled “primaryKey?”TPrimaryKey
schema?
Section titled “schema?”Schema<TDecoded, TEncoded>
Returns
Section titled “Returns”object
columnType
Section titled “columnType”columnType:
TColumnType
default
Section titled “default”default:
TDefaultextendsNoDefault?Option.None<never> :Option.Some<NoInfer<TDefault>>
nullable
Section titled “nullable”nullable:
NoInfer<TNullable>
primaryKey
Section titled “primaryKey”primaryKey:
NoInfer<TPrimaryKey>
schema
Section titled “schema”schema:
TNullableextendstrue?Schema<NoInfer<TDecoded> |null,NoInfer<TEncoded> |null> :Schema<NoInfer<TDecoded>,NoInfer<TEncoded>>