Closed
Description
Repro
{
"rules": {
"@typescript-eslint/no-invalid-void-type": "error"
}
}
function foo (): void | never {
throw new Error('Test');
}
Expected Result
That the no-invalid-void-type does not complain about the void | never
union.
Actual Result
void is only valid as a return type or generic type variable [Error/@typescript-eslint/no-invalid-void-type]
Versions
package | version |
---|---|
@typescript-eslint/eslint-plugin |
2.30.0 |
@typescript-eslint/parser |
2.30.0 |
TypeScript |
3.9.0-dev.20200419 |
ESLint |
6.8.0 |
node |
13.6.0 |
npm |
6.14.4 |