TypeStat
TypeStat copied to clipboard
Incomplete union function types fixer doesn't wrap original function in parenthesis
🐛 Bug Report
- TypeStat version: 0.4.1
- TypeScript version: 4.1.2
- Node version: N/A
Actual Behavior
- let returnsEither: () => string;
+ let returnsEither: () => string | (() => number);
returnsEither = () => "";
returnsEither = () => 7;
Expected Behavior
The () => string should be wrapped in () too.
Reproduction
See ☝️