A Symbol that represents the absense of at value at runtime - similar idea to never type in TypeScript.
Usually we use undefined for these cases, but we want to recognise undefined as a separate valid in JS data, that occurs when something is not defined.
NOTHING is used to represent a real never value, used in the z.loop() family functions to represent the absense of a value. We don't name it never (or void) so it's not inconsistent with TypeScript's typing system - but it might be renamed in the future.
A Symbol that represents the absense of at value at runtime - similar idea to
never
type in TypeScript.Usually we use
undefined
for these cases, but we want to recogniseundefined
as a separate valid in JS data, that occurs when something is not defined.NOTHING
is used to represent a realnever
value, used in thez.loop()
family functions to represent the absense of a value. We don't name itnever
(orvoid
) so it's not inconsistent with TypeScript's typing system - but it might be renamed in the future.