ClipboardEvent.clipboardData
Baseline Widely available
This feature is well established and works across many devices and browser versions. It’s been available across browsers since March 2017.
ClipboardEvent.clipboardData
属性保存了一个 DataTransfer
对象,这个对象可用于:
- 描述哪些数据可以由
cut
和copy
事件处理器放入剪切板,通常通过调用setData(format, data)
方法; - 获取由
paste
事件处理器拷贝进剪切板的数据,通常通过调用getData(format)
方法
规范
Specification |
---|
Clipboard API and events # clipboardevent-clipboarddata |
浏览器兼容性
Report problems with this compatibility data on GitHubdesktop | mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
clipboardData |
Legend
Tip: you can click/tap on a cell for more information.
- Full support
- Full support
The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.
参见
- 与复制相关的事件:
copy
,cut
,paste
- 本对象所属的
ClipboardEvent
接口。