--- category: Browser related: - useClipboard --- # useClipboardItems Reactive [Clipboard API](https://developer.mozilla.org/en-US/docs/Web/API/Clipboard_API). Provides the ability to respond to clipboard commands (cut, copy, and paste) as well as to asynchronously read from and write to the system clipboard. Access to the contents of the clipboard is gated behind the [Permissions API](https://developer.mozilla.org/en-US/docs/Web/API/Permissions_API). Without user permission, reading or altering the clipboard contents is not permitted. ## Difference from `useClipboard` `useClipboard` is a "text-only" function, while `useClipboardItems` is a [ClipboardItem](https://developer.mozilla.org/en-US/docs/Web/API/ClipboardItem) based function. You can use `useClipboardItems` to copy any content supported by [ClipboardItem](https://developer.mozilla.org/en-US/docs/Web/API/ClipboardItem). ## Usage ```vue ``` ## Type Declarations ```ts export interface UseClipboardItemsOptions extends ConfigurableNavigator { /** * Enabled reading for clipboard * * @default false */ read?: boolean /** * Copy source */ source?: Source /** * Milliseconds to reset state of `copied` ref * * @default 1500 */ copiedDuring?: number } export interface UseClipboardItemsReturn { isSupported: ComputedRef content: Readonly> copied: Readonly> copy: Optional extends true ? (content?: ClipboardItems) => Promise : (text: ClipboardItems) => Promise read: () => void } /** * Reactive Clipboard API. * * @see https://vueuse.org/useClipboardItems * @param options * * @__NO_SIDE_EFFECTS__ */ export declare function useClipboardItems( options?: UseClipboardItemsOptions, ): UseClipboardItemsReturn export declare function useClipboardItems( options: UseClipboardItemsOptions>, ): UseClipboardItemsReturn ```