-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Bug: [no-invalid-void-type] better report message for void used as a constituent inside a function return type #5255
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
That is working as expected. Please see the rule docs |
Oh, I see. The error message is a little misleading then, maybe we should update it? |
Good point - yes, we can special case the error message in the case of a union or intersection type directly used as a function's return type. |
@Zamiell I push pr about this issue! Please check it if what you intended! |
@JoshuaKGoldberg @Zamiell |
Sorry, I don't follow? |
@JoshuaKGoldberg I don't have enough time to solve this , so can I hand it over to someone else? |
Before You File a Bug Report Please Confirm You Have Done The Following...
Playground Link
https://typescript-eslint.io/play/#ts=4.7.2&sourceType=module&code=CYUwxgNghgTiAEAzArgOzAFwJYHtVJxwAoBKALnlWQFsAjEGeAH3gDcctgBuAWACggA&eslintrc=N4KABGBEBOCuA2BTAzpAXGUEKQAIBcBPABxQGNoBLY-AWhXkoDt8B6Jge1uYDcBDRgBNaPDpWFFS6KAHc+0JpHBgAviDVA&tsconfig=N4KABGBEDGD2C2AHAlgGwKYCcDyiAuysAdgM6QBcYoEEkJemy0eAcgK6qoDCAFutAGsylBm3TgwAXxCSgA
The text was updated successfully, but these errors were encountered: