interface TicketTime {
startTime: string;
endTime: string;
}
interface TicketInfo {
id: number;
from: string;
to: string;
company: string;
price: number;
time: TicketTime;
duration: number;
connectionAmount: number | null;
}
type info = TicketInfo [];
let flightsData: info [
{
}, ]
Playground
I don’t understand why this error appears and how to fix it.
New contributor
Melman is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.