ClipboardEvent.clipboardData
Experimental: This is an experimental technology
Check the Browser compatibility table carefully before using this in production.
The ClipboardEvent.clipboardData property holds a DataTransfer object, which can be used:
- to specify what data should be put into the clipboard from the
cutandcopyevent handlers, typically with asetData(format, data)call; - to obtain the data to be pasted from the
pasteevent handler, typically with agetData(format)call.
See the cut, copy, and paste events documentation for more information.
Syntax
data = ClipboardEvent.clipboardData
Specifications
| Specification |
|---|
| Clipboard API and events # clipboardevent-clipboarddata |
Browser compatibility
| Desktop | Mobile | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | WebView Android | Chrome Android | Firefox for Android | Opera Android | Safari on IOS | Samsung Internet | |
clipboardData |
58 |
12 |
22 |
5 |
45 |
10.1 |
58 |
58 |
22 |
43 |
10.3 |
7.0 |
See also
- Copy-related events:
copy,cut,paste - The
ClipboardEventinterface it belongs to. - Clipboard API
© 2005–2021 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/ClipboardEvent/clipboardData