import { Left } from './Left' ; import { Right } from './Right' ; name type export type Either < A , B > = Left < A > | Right < B > ; export namespace Either { name export const of = Right . of ; name export const left = Left . of ; } name export function isLeft < A , B > ( either ) { return either . hasOwnProperty ( '@typed/Left' ) ; } name export function isRight < A , B > ( either ) { return either . hasOwnProperty ( '@typed/Right' ) ; }