How can I use type parameter T in the next code block (typeOf, instanceOf, ...). T 'group' is it possible because javascript is not type in thaaks
class group {} function getKey (item: any): string {if (item item of group) "group "Returns; Other refunds 'invalid'; } Console.log (getKey (new group ()));
There is no typecript magic in the code above. We are simply using the JavaScript example operator:
Comments
Post a Comment