-
-
Save dimitris-papadimitriou-chr/ac5aaa46f0bf369b8812fd39d58afb26 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export interface Product { getPrice: () => number;} | |
export var ProductA: (price: number) => Product = (price: number) => ({ | |
getPrice: () => price | |
}); | |
export var Packaging: (product: Product) => Product = (product: Product) => ({ | |
getPrice: () => product.getPrice() + 0.5 | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment