Loop Through Object Javascript Typescript Download