Converts an optional value to an array, handling undefined cases.
The type of the input value
Optional input value
An array containing the value, or an empty array if undefined
maybe(5) // [5]maybe(undefined) // [] Copy
maybe(5) // [5]maybe(undefined) // []
Converts an optional value to an array, handling undefined cases.