Get Last Object In Array Typescript Compiler Commando