Javascript Map Over Empty Array Typescript Compiler