This repository has been archived by the owner on Jul 15, 2023. It is now read-only.
no-function-expression
and generic functions in TSX
#518
Labels
Difficulty: Easy
Someone with little to no experience in TSLint should be able to send a pull request for this issue.
Status: Accepting PRs
Type: Bug
Milestone
While the following is supported by the language:
The following is not:
no-function-expression
encourages to use arrow functions, which can lead to the following to make the linter pass (or disable the linter on a case-by-case basis):Which isn't great. See https://stackoverflow.com/questions/32308370/what-is-the-syntax-for-typescript-arrow-functions-with-generics
Similarly to the fact that function expressions that contain a
this
reference are allowed and will not create a failure, it would be nice if function expressions that have a generic type were allowed.Thoughts?
The text was updated successfully, but these errors were encountered: