Exploring Typescript and Angular2 for the first time has been a learning experience, especially when it comes to classes and interfaces.
Take a look at my interface:
export interface Discount {
codSco: string;
desSco: string;
}
Now I'm attempting to create an instance of type Discount in the following routine:
var Discount;
s.codSco = '44';
s.desSco = '44';
Unfortunately, this results in the error message:
TypeError: s is undefined
I'm thinking maybe I need to build a class that inherits from the interfaces. Can you offer some guidance on how to do this?
Thank you