nadbm / react-datasheet

Excel-like data grid (table) component for React
https://nadbm.github.io/react-datasheet/
MIT License
5.39k stars 457 forks source link

Feature Request: Export as Excel/CSV #322

Open maifeeulasad opened 2 years ago

maifeeulasad commented 2 years ago

I used this library for my project, and I must say it's an excellent library.

I went through all the examples provided in the official demo: https://nadbm.github.io/react-datasheet/. But couldn't find any way to export data as an Excel document or even CSV. I think it would be a great addition.

And I'm available to develop this feature.

nadbm commented 2 years ago

Hey @maifeeulasad, since this library does not maintain the data, I do not believe it makes sense for it to export the data.

Basically:

const data = [...]
render () {
     <ReactDatasheet data={data} /> <Export data={data} />
}

The export could be seperate component that handles the export

sharunspi commented 2 years ago

It should be great if the library is having a action bar component in which it will be having all the options similar to the option in any excel sheets. image

  1. Can add config file to configure the options
  2. Can add multiple options like export to csv,json,etc