Clipboard overview
Added in v1.0.0
Table of contents
constructor
make
Signature
export declare const make: (impl: Omit<Clipboard, "clear" | "writeBlob" | TypeId>) => Clipboard
Added in v1.0.0
errors
ClipboardError (class)
Signature
export declare class ClipboardError
Added in v1.0.0
interface
Clipboard (interface)
Signature
export interface Clipboard {
readonly [TypeId]: TypeId
readonly read: Effect.Effect<ClipboardItems, ClipboardError>
readonly readString: Effect.Effect<string, ClipboardError>
readonly write: (items: ClipboardItems) => Effect.Effect<void, ClipboardError>
readonly writeString: (text: string) => Effect.Effect<void, ClipboardError>
readonly writeBlob: (blob: Blob) => Effect.Effect<void, ClipboardError>
readonly clear: Effect.Effect<void, ClipboardError>
}
Added in v1.0.0
layers
layer
A layer that directly interfaces with the navigator.clipboard api
Signature
export declare const layer: Layer.Layer<Clipboard>
Added in v1.0.0
tag
Clipboard
Signature
export declare const Clipboard: Context.Tag<Clipboard, Clipboard>
Added in v1.0.0
type ids
ErrorTypeId
Signature
export declare const ErrorTypeId: typeof ErrorTypeId
Added in v1.0.0
ErrorTypeId (type alias)
Signature
export type ErrorTypeId = typeof ErrorTypeId
Added in v1.0.0
TypeId
Signature
export declare const TypeId: typeof TypeId
Added in v1.0.0
TypeId (type alias)
Signature
export type TypeId = typeof TypeId
Added in v1.0.0