/** * Lift any MaybeValue or MaybeArray to an Array, skipping SoftNull (null/undefined) * @param x Maybe value (a value, or null/undefined) * @returns Array of values. * If x is null/undefined, returns an empty array. * If x is an array, returns x. * If x is a value, returns an array containing x */ export const arrayse = (...x: (T | T[] | null | undefined)[]): T[] => ([] as T[]).concat(...x.map(x=>x ?? [])) ;