Result
Discriminated ok union: either { ok: true; value } or { ok: false; error }.
ok
{ ok: true; value }
{ ok: false; error }
Every fallible public API in micro509 returns a specialization of this type.
type Result<TValue, TError> = { readonly ok: true; readonly value: TValue } | { readonly ok: false; readonly error: TError }