Appearance
将联合类型转换为交叉类型。
import { UnionToIntersection } from '@base-web-kits/base-tools-ts'; type I = UnionToIntersection<{ a: 1 } | { b: 2 }>; // 结果: { a: 1 } & { b: 2 }