We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Function
{ [[call]]: any }
Make Function alias to { [[call]]: any } instead of any
any
It would error if you provide non-callable things and also seems more safe, instead of outright any
The text was updated successfully, but these errors were encountered:
Is { [[call]]: any } equivalent to { (...args: any[]): any }?
{ (...args: any[]): any }
I didn't know about [[call]], are there any docs for it? I can't seem to find docs for callable types either.
[[call]]
Sorry, something went wrong.
There's PR for call property #7790 docs, not sure about equivalency
We now updated the docs to recommend other safer patterns: https://flow.org/en/docs/types/functions/#any-function
No branches or pull requests
Proposal
Make
Function
alias to{ [[call]]: any }
instead ofany
Use case
It would error if you provide non-callable things and also seems more safe, instead of outright
any
The text was updated successfully, but these errors were encountered: