-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Getting warnings even with allowTypedFunctionExpressions set to true #384
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
In this instance, you have eslint misconfigured.
I.e. for {
"rules": {
"@typescript-eslint/explicit-function-return-type": ["error", {
"allowTypedFunctionExpressions": true
}],
}
} |
Thanks! |
@bradzacher I made the changes and it works for tsx files, but when I run lint, it fails on test files. Since I already have the types included, it shouldn't? |
I have that enabled as well, but I still see an error |
I put in core-js3 in my babel config and the issue got resolved. Not sure why though. |
Should @typescript-eslint not default to enabling allowTypedFunctionExpressions. Seems like everyone would face this issue otherwise? Am i overlooking something? |
It's going to be the default in v2. There is a PR waiting to be merged (the last one before the v2 release) |
After adding the
rules: { allowTypedFunctionExpressions: true }
for the alpha release (#149), I still see them as warnings
Repro
Code repo: https://github.com/saranshkataria/frontend-starter-kit
Expected Result
No warnings
Actual Result
Get warnings
Additional Info
Versions
@typescript-eslint/eslint-plugin
1.5.1-alpha.5
@typescript-eslint/parser
1.5.1-alpha.5
TypeScript
3.3.4000
ESLint
5.15.3
node
8.15.0
npm
6.4.1
The text was updated successfully, but these errors were encountered: