You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Your decorate<Foo>() call returns a function that accepts and returns an instance of Foo, but then you pass it the constructor functionFoo, which is not the same type, hence the error.
I'm not sure whether you mean to work with Foo instances or Foo constructors, but the following variants both pass type checks:
TypeScript Version:
1.8.0
Code
How can there be a type mismatch if it's the same type? 😖
The text was updated successfully, but these errors were encountered: