Open
Description
Flow offer some nice type helpers in his recent versions, while some of them are already addressed by typescript, some could perhaps be helpful.
Here are extracted comments from flow source just for inspiration.
- $Either<...T> is the union of types ...T
- $All<...T> is the intersection of types ...T
- $Supertype acts as any over supertypes of T
- $Subtype acts as any over subtypes of T
- $Shape matches the shape of T
- $Diff<T,S>
- $Enum is the set of keys of T
- $Record is the type of objects whose keys are those of T
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment