Heap.Unknown
Declares a field of type unknown
.
The value of the field is not validated in any way, but it can only be data that is serializable to JSON. Its practical application is questionable. It exists for the sake of completeness in covering the Typescript types system.
Usage / Signature
import { Heap } from '@app/heap'
Heap.Unknown(options)
Arguments
-
<b id="options">options</b>:
{
default}
An object with additional optional parameters for the field.- <b id="default">default</b>:
unknown
The default value for this field. For more information on how default values work, see Guide / Heap / Default Values
- <b id="default">default</b>:
Return Value
An empty JSON schema.
Examples
Unknown field with null as the default value
const tasks = Heap.Table('tasks', {
done: Heap.Unknown({ default: null }),
})