Search


Search something to see results

pattern

Parameters

  • regexp: RegExp

Returns Object

import * as x from 'unhoax'

const pattern = x.pattern(/^https?://.+/)
const withUrlPattern = pattern(x.string)

const url = withUrlPattern(x.string)
// Schema<string>