Skip to content
Effect Days 2026 Get your ticket

Error

11 exports Added in v1.0.0 Source

Error

TypeIdError

Added in v1.0.0 Source

Signature

declare function TypeIdError<TypeId extends symbol, Tag extends string>(typeId: TypeId, tag: Tag): <A extends Record<string, any>>(args: Simplify<A>) => YieldableError & Record<TypeId, TypeId> & {
readonly _tag: Tag;
} & Readonly<A>

Model

Signature

declare const SystemErrorReason: Literal<"AlreadyExists">

SystemErrorReason type

Added in v1.0.0 Source

Signature

type SystemErrorReason = typeof SystemErrorReason.Type

Models

BadArgument

Added in v1.0.0 Source

Signature

declare class BadArgument extends {
readonly _tag: "BadArgument";
readonly cause?: unknown;
readonly description?: string;
readonly method: string;
readonly module: "Clipboard";
} & YieldableError<this> {
constructor(...args: [props: {
readonly _tag?: "BadArgument";
readonly cause?: unknown;
readonly description?: string;
readonly method: string;
readonly module: "Clipboard";
}, options?: MakeOptions]);
readonly [TypeId]: typeof TypeId;
message: string;
}

Module

Added in v1.0.0 Source

Signature

declare const Module: Literal<"Clipboard">

Signature

declare const PlatformError: Union<[typeof BadArgument, typeof SystemError]>

PlatformError type

Added in v1.0.0 Source

Signature

type PlatformError = BadArgument | SystemError

Models

SystemError

Added in v1.0.0 Source

Signature

declare class SystemError extends {
readonly _tag: "SystemError";
readonly cause?: unknown;
readonly description?: string;
readonly method: string;
readonly module: "Clipboard";
readonly pathOrDescriptor?: unknown;
readonly reason: "AlreadyExists";
readonly syscall?: string;
} & YieldableError<this> {
constructor(...args: [props: {
readonly _tag?: "SystemError";
readonly cause?: unknown;
readonly description?: string;
readonly method: string;
readonly module: "Clipboard";
readonly pathOrDescriptor?: unknown;
readonly reason: "AlreadyExists";
readonly syscall?: string;
}, options?: MakeOptions]);
readonly [TypeId]: typeof TypeId;
message: string;
}

Refinements

Signature

declare function isPlatformError(u: unknown): u is PlatformError

Type Id

TypeId

Added in v1.0.0 Source

Signature

declare const TypeId: unique symbol

TypeId type

Added in v1.0.0 Source

Signature

type TypeId = typeof TypeId