Gathering detailed insights and metrics for @github/clipboard-copy-element
Gathering detailed insights and metrics for @github/clipboard-copy-element
Gathering detailed insights and metrics for @github/clipboard-copy-element
Gathering detailed insights and metrics for @github/clipboard-copy-element
Copy element text content or input values to the clipboard.
npm install @github/clipboard-copy-element
Typescript
Module System
Node Version
NPM Version
98.9
Supply Chain
99.1
Quality
83.1
Maintenance
100
Vulnerability
100
License
JavaScript (56.32%)
TypeScript (36.25%)
Dockerfile (7.44%)
Total Downloads
4,887,540
Last Day
3,516
Last Week
38,210
Last Month
172,394
Last Year
1,985,705
MIT License
475 Stars
239 Commits
262 Forks
312 Watchers
3 Branches
3,905 Contributors
Updated on Jun 09, 2025
Minified
Minified + Gzipped
Latest Version
1.3.0
Package Id
@github/clipboard-copy-element@1.3.0
Unpacked Size
14.30 kB
Size
4.52 kB
File Count
12
NPM Version
9.8.1
Node Version
18.18.0
Published on
Sep 28, 2023
Cumulative downloads
Total Downloads
Last Day
-0.8%
3,516
Compared to previous day
Last Week
-9.7%
38,210
Compared to previous week
Last Month
2.9%
172,394
Compared to previous month
Last Year
10.3%
1,985,705
Compared to previous year
20
Copy element text content or input values to the clipboard.
$ npm install --save @github/clipboard-copy-element
Import as ES modules:
1import '@github/clipboard-copy-element'
With a script tag:
1<script type="module" src="./node_modules/@github/clipboard-copy-element/dist/index.js">
1<clipboard-copy for="blob-path" class="btn btn-sm BtnGroup-item"> 2 Copy path 3</clipboard-copy> 4<div id="blob-path">src/index.js</div>
1<clipboard-copy value="src/index.js">Copy</clipboard-copy>
1<clipboard-copy for="blob-path">Copy</clipboard-copy> 2<div id="blob-path">src/index.js</div>
1<clipboard-copy for="blob-path">Copy</clipboard-copy> 2<input id="blob-path" value="src/index.js">
1<clipboard-copy for="blob-path">Copy full URL</clipboard-copy> 2<a id="blob-path" href="/path/to#my-blob">Link text will not be copied</a>
After copying to the clipboard, a clipboard-copy
event is dispatched from
the <clipboard-copy>
element:
1document.addEventListener('clipboard-copy', function(event) { 2 const button = event.target 3 button.classList.add('highlight') 4})
Browsers without native custom element support require a polyfill.
npm install
npm test
Distributed under the MIT license. See LICENSE for details.
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
security policy file detected
Details
Reason
Found 2/4 approved changesets -- score normalized to 5
Reason
SAST tool is not run on all commits -- score normalized to 4
Details
Reason
4 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 3
Reason
dependency not pinned by hash detected -- score normalized to 1
Details
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
Reason
10 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-06-23
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More