Answers for "indexable type in ts"

0

indexable type in ts

//Indexable type Typescript 
interface ListItem {
  [prop: string ] : string | number ;
}

const List: ListItem = {
  name: "joyous jackal" ;
  email: "[email protected]";
  age: 21 ;
}
Posted by: Guest on October-17-2020

Code answers related to "TypeScript"

Browse Popular Code Answers by Language