Run ❯
Get your
own
website
×
Change Orientation
Change Theme, Dark/Light
Go to Spaces
interface Car { make: string; model: string; mileage?: number; } let myCar: Required
= { make: 'Ford', model: 'Focus', mileage: 12000 // `Required` forces mileage to be defined }; console.log(myCar);
{ make: 'Ford', model: 'Focus', mileage: 12000 }