
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
Vue.js directive to download (and optionally transform) data
For browser usage, import the component by adding a src tag in the header ():
<script src="https://unpkg.com/v-download@1.2.0/dist/main.js">
For Node usage, install the v-download package using npm
npm install --save v-download
First register the directive globally:
import DownloadData from 'v-download'
Vue.use(DownloadData)
Or locally:
import { downloadData } from 'v-download'
export default {
directives: {
downloadData
}
}
Then use it in template:
<template>
<button v-download-data="`some text`">Download!</button>
</template>
If type is provided it will be used as the mimetype:
<template>
<button v-download-data="`{'example':'some text'}`" v-download-data:type="'json'">Download!</button>
</template>
If an object or array (instead of a string) is provided and the type is 'csv', 'tsv' or 'json', the object/array will be converted (json will be convert using JSON.stringify, csv/tsv is assuming an array and will be iterated)
<template>
<button v-download-data="myObject" v-download-data:type="'json'">Download!</button>
</template>
If filename is provided it will be used as the downloaded file name:
<template>
<button v-download-data="`{'example':'some text'}`" v-download-data:filename="'mydownload.json'">Download!</button>
</template>
FAQs
Vue.js directive to download (and optionally transform) data
The npm package v-download receives a total of 96 weekly downloads. As such, v-download popularity was classified as not popular.
We found that v-download demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.