In my angular2 app i want to create a map which takes a number as key and returns an array of objects. I am currently implementing in following way but no luck. How should i imp
The most simple way is to use Record type Record
interface productDetails { productId : number , price : number , discount : number }; const myVar : Record = { 1: { productId : number , price : number , discount : number } }