1.0.1 • Published 8 years ago

client-side-csv-download v1.0.1

Weekly downloads
111
License
MIT
Repository
github
Last release
8 years ago

client-side-csv-download

downloads csv string as file on the client-side

install

npm i --save client-side-csv-download

usage

import downloadCSV from 'client-side-csv-download'
import toCSV from 'array-to-csv'

var csvString = toCSV(
  ['words', 'count'],
  ['aut', 2],
  ['fugit', 3]
)

downloadCSV({
  csvString: csvString,
  filename: 'histogram' // downloads histogram.csv
})