Object Shapes
Object Shapes
π¨βπΌ Let's create interfaces for our domain objects. Interfaces are the standard
way to define object shapes in TypeScript.
π¨ Open
and:
- Create a
Productinterface with a union type property - Create a function that accepts this interface