Socket
Socket
Sign inDemoInstall

create-download-link

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

create-download-link - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

2

package.json
{
"name": "create-download-link",
"version": "1.0.3",
"version": "1.0.4",
"description": "Create link to download text as file",

@@ -5,0 +5,0 @@ "main": "index.js",

[![Build Status](https://travis-ci.org/fhinkel/create-download-link.svg?branch=master)](https://travis-ci.org/fhinkel/create-download-link)
[![Coverage Status](https://coveralls.io/repos/github/fhinkel/create-download-link/badge.svg?branch=master)](https://coveralls.io/github/fhinkel/create-download-link?branch=master)
[![NPM](https://nodei.co/npm/create-download-link.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/create-download-link/)
# create-download-link
*create-download-link* returns the following DOM element:
With this package, you can easily create links for downloading content as files.
*create-download-link* returns a DOM element like the following:
```html

@@ -11,9 +13,13 @@ <a href="data:application/octet-stream,data" download="filename">title</a>

Specify the content of the file as a string, the filename to be used, and
the title of the anchor element. When the element is clicked, a file is
downloaded.
Specify the
- **content** of the file as a string,
- the **filename** to be used, and
- the **title** of the anchor element.
## Example
When the element is clicked, a file is
downloaded and saved as *filename*.
## Usage
```javascript

@@ -20,0 +26,0 @@ var createDownloadLink = require('create-download-link');

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc