Understanding Arity in `Function.dual` with Optional and Unknown Parameters

hi, i am trying to use dual api once again, and again i got confused how arity works in Function.dual

static fromUnknownError(message?: string, options?: Omit<TaggedInternalErrorOptions, 'cause'>) {
  return (error: unknown) => new UserAvatarError(message, { ...options, cause: inferCauseFromUnknownError()(error) })
}


i want to convert this into dual api using Function.dual but i dont understand what to pass in arity when fields are optional and unknown
Was this page helpful?