react-data-export
react-data-export copied to clipboard
How to export data to xsl?
I want a .xls excel file I tried the porps fileExtension="xls" but I can not open the file.
const multiDataSet = [
{
columns: [{ title: 'Date' }, { title: 'Valeur 1' }, { title: 'Valeur 2' }],
data: [[{ value: 'Dat1' }, { value: '10' }, { value: '12' }]]
}
];
//...
<ExcelFile
fileExtension='xls'
element={<button>Download Data</button>}>
<ExcelSheet dataSet={multiDataSet} name='ChartData' />
</ExcelFile>