I'm trying to create an interface for Object, objects, and array of objects.
Sample interface
export interface ErateColumn {
categories:{
[key:string]:column[]
}
}
interface column {
label:string
value:string
}
Sample API response like this
{
"categories": {
"Basic Information": [
{ label: "Applicant Type", value: "ApplicantType" },
{ label: "Organization Name", value: "OrganizationName" },
],
"FRN Lineitem": [
{ label: "Monthly_Cost", value: "Monthly_Cost" },
],
"FRN status": [
{ label: "Purpose Type", value: "PurposeType" },
]
}
}
