Skip to main content

Undefined

The value undefined represents a value that is not present.

You would receive undefined for example if you look up a key in a map that does not exist. Typically you should never store undefined is value anywhere. It should only be used in transit as a signal to indicate a missing value.

let a = [1, 2, 3, null, 5]
a[2] // 3 (because array indices start from 0 in Easel)
a[3] // null
a[4] // 5
a[10] // undefined because a only has 5 elements