Skip to main content
Home
This release is 1 version behind 1.2.1 — the latest version of @core/errorutil. Jump to latest

Built and signed on GitHub Actions

Works with
This package works with Node.js, DenoIt is unknown whether this package works with Cloudflare Workers, Browsers
It is unknown whether this package works with Cloudflare Workers
This package works with Node.js
This package works with Deno
It is unknown whether this package works with Browsers
JSR Score100%
Downloads151/wk
Publisheda year ago (1.2.0)

An utility pack for handling error

f
attempt

Attempt to execute a function and return a Result<T, E>.

T
ErrorObject

An error object is a serializable representation of an error

T
Failure
No documentation available
f
fromErrorObject

Convert an error object to an error

f
isErrorObject

Check if a value is an error object

f
raise

Throw an error.

T
Result
No documentation available
T
Success
No documentation available
f
toErrorObject

Convert an error to an error object

f
tryOr

Try to execute a function and return the result or a default value if an error occurs.

f
tryOrElse

Try to execute a function and return the result or execute another function and return its result if an error occurs.

f
unimplemented

Function indicating that this part is unimplemented.

c
UnimplementedError

Error indicating that this part is unimplemented.

f
unreachable

Function indicating that this part is unreachable.

c
UnreachableError

Error indicating that this part is unreachable.

f
alter

Alter the error of a function if an error is thrown.

f
alterElse

Alter the error of a function if an error is thrown.

f
attempt

Attempt to execute a function and return a Result<T, E>.

T
Failure
No documentation available
T
Result
No documentation available
T
Success
No documentation available
T
ErrorObject

An error object is a serializable representation of an error

f
fromErrorObject

Convert an error object to an error

f
isErrorObject

Check if a value is an error object

f
toErrorObject

Convert an error to an error object

f
raise

Throw an error.

f
tryOr

Try to execute a function and return the result or a default value if an error occurs.

f
tryOrElse

Try to execute a function and return the result or execute another function and return its result if an error occurs.

f
unimplemented

Function indicating that this part is unimplemented.

c
UnimplementedError

Error indicating that this part is unimplemented.

f
unreachable

Function indicating that this part is unreachable.

c
UnreachableError

Error indicating that this part is unreachable.

Report package

Please provide a reason for reporting this package. We will review your report and take appropriate action.

Please review the JSR usage policy before submitting a report.