react-file-download

WebJar for react-file-download

Лицензия

Лицензия

MIT
Категории

Категории

React Взаимодействие с пользователем Веб-фреймворки
Группа

Группа

org.webjars.npm
Идентификатор

Идентификатор

react-file-download
Последняя версия

Последняя версия

0.3.5
Дата

Дата

Тип

Тип

jar
Описание

Описание

react-file-download
WebJar for react-file-download
Ссылка на сайт

Ссылка на сайт

http://webjars.org
Система контроля версий

Система контроля версий

https://github.com/kennethjiang/js-file-download

Скачать react-file-download

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.webjars.npm/react-file-download/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>react-file-download</artifactId>
    <version>0.3.5</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/react-file-download/
implementation 'org.webjars.npm:react-file-download:0.3.5'
// https://jarcasting.com/artifacts/org.webjars.npm/react-file-download/
implementation ("org.webjars.npm:react-file-download:0.3.5")
'org.webjars.npm:react-file-download:jar:0.3.5'
<dependency org="org.webjars.npm" name="react-file-download" rev="0.3.5">
  <artifact name="react-file-download" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='react-file-download', version='0.3.5')
)
libraryDependencies += "org.webjars.npm" % "react-file-download" % "0.3.5"
[org.webjars.npm/react-file-download "0.3.5"]

Зависимости

Библиотека не имеет зависимостей. Это самодостаточное приложение, которое не зависит ни от каких других библиотек.

Модули Проекта

Данный проект не имеет модулей.

Javascript File Download

Javascript function to trigger browser to save data to file as if it was downloaded.

Installation

npm install js-file-download --save

Usage

var fileDownload = require('js-file-download');
fileDownload(data, 'filename.csv');

Binary downloads

When downloading binary data, the data must be a Blob, otherwise the downloaded file will be corrupted. For example, using Axios:

import Axios from axios;
import fileDownload from 'js-file-download';

function download(url: string, filename: string) {
  Axios.get(url, {
    responseType: 'blob',
  }).then(res => {
    fileDownload(res.data, filename);
  });
}

Версии библиотеки

Версия
0.3.5