Skip to content

WorkerCallError

The error a call rejects with when the worker’s handler failed. It carries the worker-side name, message and stack, because an Error loses its class across the worker boundary.

Import:

import { WorkerCallError } from '@mnaoumov/obsidian-lib/components/worker-component';

Signature:

export class WorkerCallError extends Error

Extends: Error

Constructor

new WorkerCallError(error: SerializedWorkerError)

Creates the error.

Properties

PropertyTypeDescription
remoteNamestringThe name of the error thrown in the worker.
remoteStackstring | undefinedThe stack of the error thrown in the worker, when there was one.