-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Allow call signatures on classes #619
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I'm warming up to the idea of allowing call signatures to be part of a class declaration. I think it would be meaningful to consider them a new form of overload of the constructor and validate (by some new rule) that the constructor implementation signature satisfies the contract implied by both kinds of overload signatures (just like we do with regular overloads). I don't think automatically injecting |
Thanks Anders! Bless your heart. ;) |
There is already a similar issue #183 |
Thanks for the pointer to 183 -- closing as duplicate. |
Ok, thanks. I did search for an existing request, and nothing came up, not sure how I missed it. |
From here: https://typescript.codeplex.com/workitem/2464
I have a possible solution: Just allow this:
Other suggestion by fdecampredon was:
could be transformed into that :
The text was updated successfully, but these errors were encountered: