export const removeUndefined = (arr: Array) => { return arr.filter((x) => x !== undefined) as T[] }