Opens in a new tab
A picture of Jeff Brigman
I CODE TODAY FOR
A BETTER TOMORROW

Glossary Term

Clipboard.readText()

3 tags 1 category

The readText() method of the Clipboard interface returns a Promise which fulfills with a copy of the textual contents of the system clipboard.

Note: To read non-text contents from the clipboard, use the read() method instead. You can write text to the clipboard using writeText().

Returns: A Promise that resolves with a string containing the textual contents of the clipboard.

Returns: Returns an empty string if the clipboard is empty, does not contain text, or does not include a textual representation among the objects representing the clipboard’s contents.

Exceptions: NotAllowedError DOMException Thrown if the access to read the clipboard is not allowed. NotFoundError DOMException Thrown if the clipboard indicates that it contains data that can be represented as a text but is unable to provide a textual representation.

Term Connections

Explore related terms connected by shared tags, shared categories, and relationship phrases. This map loads only when it comes into view.

Loading term connections…