You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Good point. I don't think restricting it to false makes much sense. Probably it was just a small oversight and the similar one just below already have boolean | void, so probably we can do the same for onConsoleLog.
Clear and concise description of the problem
According to @bradzacher in typescript-eslint/typescript-eslint#8576 (comment) the current typing of the method is flawed. As the current
void
part of the method would indicate that you shouldn't care about the result.Suggested solution
Change the return signature of
onConsoleLog
tofalse | undefined
orboolean | undefined
.The later variant especially would allow for ternaries or simple return expressions like:
Alternative
No response
Additional context
https://vitest.dev/config/#onconsolelog
Validations
The text was updated successfully, but these errors were encountered: