Security News
Weekly Downloads Now Available in npm Package Search Results
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
A tiny ~.5kb tool to save stuff. It opens a saveAs like dialog on browser.
yarn add xave
npm install xave
The xave function accepts 2 arguments. First argument is an url string, Blob or Blob URI, second one is the "name.extension"
string of the file you want to save.
xave(Blob|URL|URI, "name.extension")
import save from "xave"
// Or
const save = require("xave")
const blob = new Blob(["xd"], { type: "text/plain" })
save(blob, "text.txt")
const save = require("xave")
//PDF
const blob = new Blob(["someencodedcontent"], { type: "application/pdf" })
save(blob, "report.pdf")
//images
const image = new Blob(["someencodedcontent"], { type: "image/png" })
save(image, "image.png")
//Canvas
const canvas = window.canvas
const ctx = canvas.getContext("2d")
ctx.fillStyle = "red"
ctx.beginPath()
ctx.arc(15, 15, 15, 0, Math.PI * 2, true)
ctx.closePath()
ctx.fill()
const url = canvas.toDataURL()
save(url)
<script src="https://d3portillo.github.io/xave/src/index.min.js"></script>
FAQs
📦 Tiny tool to save stuff similar to the saveAs dialog
We found that xave 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
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
Security News
A Stanford study reveals 9.5% of engineers contribute almost nothing, costing tech $90B annually, with remote work fueling the rise of "ghost engineers."
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.