Gathering detailed insights and metrics for v-clipboard
Gathering detailed insights and metrics for v-clipboard
Gathering detailed insights and metrics for v-clipboard
Gathering detailed insights and metrics for v-clipboard
npm install v-clipboard
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
520 Stars
100 Commits
39 Forks
6 Watching
1 Branches
6 Contributors
Updated on 04 Nov 2024
TypeScript (100%)
Cumulative downloads
Total Downloads
Last day
0.8%
5,040
Compared to previous day
Last week
8.8%
28,007
Compared to previous week
Last month
5.1%
114,284
Compared to previous month
Last year
-25.2%
1,512,253
Compared to previous year
1
6
Check them out.
1npm install --save v-clipboard
1yarn add v-clipboard
1import Vue from 'vue' 2import Clipboard from 'v-clipboard' 3 4Vue.use(Clipboard)
When an element that contains v-clipboard
directive is clicked, the value of value
will be copied into clipboard.
Copying static value (directive should receive actual value):
1<button v-clipboard="value"> 2 Copy to clipboard 3</button>
1<button v-clipboard="'some text'"> 2 Copy to clipboard 3</button>
Copying dynamic value (directive should recieve a function that returns value):
1<button v-clipboard="() => value"> 2 Copy to clipboard 3</button>
Copying anything in your methods:
1this.$clipboard(value)
Without plugin:
1import { Clipboard } from 'v-clipboard' 2 3await Clipboard.copy(value)
1<button 2 v-clipboard="foo" 3 v-clipboard:success="clipboardSuccessHandler" 4 v-clipboard:error="clipboardErrorHandler" 5> 6 Copy to clipboard 7</button>
1{ 2 methods: { 3 clipboardSuccessHandler (value, event) { 4 console.log('success', value) 5 }, 6 7 clipboardErrorHandler (value, event) { 8 console.log('error', value) 9 } 10 } 11}
copy / $clipboard
is an async
call. Firstly, library makes an attempt to update clibpoard using execCommand
, if that operation is unsuccessful it makes an attemnt to use Navigator Clipboard API and automatically requests access, waits for access to be granted, then writes to clipboard.
https://codesandbox.io/s/epic-waterfall-17yet5?file=/src/App.vue
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no SAST tool detected
Details
Reason
Found 0/30 approved changesets -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
11 existing vulnerabilities detected
Details
Score
Last Scanned on 2024-11-25
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