/** * Checks if two types are exactly equal. * * `Equal` returns `true` if types X and Y are identical, `false` * otherwise. Works with any TypeScript types including unions. * * @author Kyungsu Kang - https://github.com/kakasoo * @template X First type to compare * @template Y Second type to compare */ export type Equal = (() => T extends X ? 1 : 2) extends () => T extends Y ? 1 : 2 ? true : false;