Documentation / @warp-drive/schema-record / fromIdentity
Variable: fromIdentity
ts
const fromIdentity: FromIdentityDerivation;
Defined in: schema.d.ts:126
A derivation that computes its value from the record's identity.
It can be used via a derived field definition like:
ts
{
kind: 'derived',
name: 'id',
type: '@identity',
options: { key: 'id' }
}
Valid keys are 'id'
, 'lid'
, 'type'
, and '^'
.
^
returns the entire identifier object.