Returns true if the data type is a Primitive, according to the definition of "primitive" in JavaScript
true
Boxed Primitives
Boxed / object versions of primitives result to false in z.isPrimitive, i.e they are NOT considered primitives (they are Boxed Primitives).
z.isPrimitive
This is in contrast to isSingle that considers boxed values as z.isSingle and their z.type is their designated type.
isSingle
z.isSingle
z.type
To check Boxed Primitives, use z.isBoxedPrimitive() or use the individual z.isBoxedXxx functions.
z.isBoxedPrimitive()
z.isBoxedXxx
z.isSingle()
isPrimitive
z.isMany()
any value
true if the value is a primitive type
Returns
true
if the data type is a Primitive, according to the definition of "primitive" in JavaScriptBoxed Primitives
Boxed / object versions of primitives result to false in
z.isPrimitive
, i.e they are NOT considered primitives (they are Boxed Primitives).This is in contrast to
isSingle
that considers boxed values asz.isSingle
and theirz.type
is their designated type.To check Boxed Primitives, use
z.isBoxedPrimitive()
or use the individualz.isBoxedXxx
functions.See
z.isSingle()
is a broader version ofisPrimitive
z.isMany()
is the opposite ofisSingle