Editor model · function
formatValue
A value as a row shows it.
function formatValue(value: unknown, kind: string): stringimport { formatValue } from '@driftengine/editor';Parameters
| Parameter | Type | Description |
|---|---|---|
value | unknown | |
kind | string |
In depth
A boolean reads as a word and an enum as its number, which is as far as this can honestly go:
the variant list belongs to the module that declared the enum, and a component is handed
enum:Mood — a name and no variants. A consumer holding the list formats its own.