Skip to content

rulvar API reference


rulvar API reference / @rulvar/rulvar / toJournalValue

Function: toJournalValue()

ts
function toJournalValue(value, site): Json;

Defined in: packages/core/dist/index.d.ts

Validates and snapshots a value for the journal: the returned value is a JSON round-trip clone, decoupled from later caller mutations, with undefined object members dropped.

Parameters

ParameterType
valueunknown
sitestring

Returns

Json