Search


Search something to see results

or

Type Parameters

  • B
  • InputB = unknown

Parameters

Returns Object

union

import { x } from 'unhoax'
import pipe from 'just-pipe' // or from elsewhere

const schema = pipe(x.number, x.or(x.string)) // Schema<number | string>
import { x } from 'unhoax'

const orString = x.or(x.string)
const schema = orString(x.number) // Schema<number | string>