Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!DOCTYPE html>
<meta charset="utf-8">
<title>DataTransferItemList remove() method</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
"use strict";
test(() => {
const dt = new DataTransfer();
// Must not throw
dt.items.remove(0);
dt.items.remove(1);
dt.items.add("data", "text/plain");
// Must not throw
dt.items.remove(1);
}, "remove()ing an out-of-bounds index does nothing");
</script>