WUI logo

Copy

A simple hook to copy text from a given HTML element to your clipboard with copy-to-clipboard library.

version

5.16.2

install

yarn add @welcome-ui/utils.copy

usage

import { Copy } from '@welcome-ui/utils.copy'

Copy an element #

Copy the content from another HTML element by creating a ref and passing it to useCopyText.

You can pass a timeout value (in milliseconds) to "reset" the copied value.

Copy a string #

You can also copy a simple string

Packages #

Dependencies #
Peer dependencies #

Previous

IconsFont