Skip to content

Function: isApiError() ​

ts
function isApiError(value): value is ApiError;

Defined in: src/core/errors/predicates.ts:23

Any non-2xx response from the API, including every subclass.

Prefer these predicates to instanceof in library code and in anything that might load two copies of this package: they check a branded marker instead of the prototype chain.

Parameters ​

ParameterType
valueunknown

Returns ​

value is ApiError