4 ms·
JSON does not define a type system, but javascript defines null as the only value of the null type. This works fine in eg typescript since you can use a type un
by bazoom42 3y ago
JSON does not define a type system, but javascript defines null as the only value of the null type. This works fine in eg typescript since you can use a type union of null and any other type, if you want to indicate a nullable value.
- VMG 3y agobut don't forget that `typeof null === 'object'` :)
- ElectricalUnion 3y agoThey're null pointer objects /s
- Izkata 3y agoDon't forget in addition to null, javascript has undefined and undefined. (the value undefined and the property-does-not-exist undefined)