Closed
Description
If we want to align discriminated unions vertically, we can write them like this
type Action =
Increment |
Decrement |
Reset
// or
type Action =
Increment
| Decrement
| Reset
It doesn't look bad, but it can be quite annoying to check if the bars are at right places when you want to add new types at the beginning or at the end or when you want to reorginize them - basically the same issue as trailing commas.
What I would love to have is this:
type Action =
| Increment
| Decrement
| Reset
It is easier to read and easier to maintain.
Metadata
Metadata
Assignees
Labels
No labels