Skip to main content
Module

x/domain_functions/src/errors.ts>ResultError

Decouple your business logic from your framework. With first-class type inference from end to end.
Go to Latest
class ResultError
extends Error
import { ResultError } from "https://deno.land/x/domain_functions@v2.6.0/src/errors.ts";

A custom error class for creating ErrorResult.

Examples

const df = mdf()(() => { throw new ResultError({ errors: [{ message: 'Some error' }], inputErrors: [{ message: 'Some input error', path: 'user.name' }], }) })

Constructors

new
ResultError(result: AtLeastOne<ErrorData>)