internal.UnionToIntersection
Home > @backstage/backend-openapi-utils
> internal
> UnionToIntersection
From https://stackoverflow.com/questions/71393738/typescript-intersection-not-union-type-from-json-schema
StackOverflow says not to do this, but union types aren't possible any other way.
Signature:
export type UnionToIntersection<U> = (U extends any ? (k: U) => void : never) extends (k: infer I) => void ? I : never;