Typescript-eslint: [no-type-alias] Conditional types are unhandled

Created on 5 Sep 2019  路  1Comment  路  Source: typescript-eslint/typescript-eslint

Repro

{
  "rules": {
    "@typescript-eslint/no-type-alias": ["error", {"allowAliases": "always"}]
  }
}
type MyType<T> = T extends number ? number : null;

Expected Result

The rule should deem this line acceptable.

Actual Result

The rule always flags with "Type unhandled are not allowed"

Additional Info

This makes me sad.

Versions

| package | version |
| ---------------------------------- | ------- |
| @typescript-eslint/eslint-plugin | 2.1.0 |
| @typescript-eslint/parser | 2.1.0 |
| TypeScript | 3.5.1 |
| ESLint | 6.3.0 |
| node | 8.10.0 |
| npm | 5.6.0 |

bug good first issue eslint-plugin

Most helpful comment

I'll look into it :eyes:

>All comments

I'll look into it :eyes:

Was this page helpful?
0 / 5 - 0 ratings