5-day Mini-Course

Build UIs that don’t suck.

Short, tactical video lessons from the creator of Tailwind CSS, delivered directly to your inbox every day for a week.

Get the free course

Copy button

A commercial license is required to use Tailwind Plus Elements. Purchase Tailwind Plus to obtain a license.

Copy any text snippet to the clipboard with a single click.

Component API

<el-copyable>

Wraps the text content that should be copied to the clipboard when the copy command is triggered.

Commands
--copyCopies the text to the clipboard.

<button>

A button that triggers the copy operation when clicked.

Data attributes (Read-only)
data-copiedPresent for two seconds after the text has been successfully copied.
data-errorPresent when the copy operation fails for whatever reason.

Examples

Basic example

To view the complete documentation, you must own a Tailwind Plus license and be signed in.