You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 lines
565 B

import{x as a}from"./xlsx-d1ed961a.js";import"./index-f4658ae7.js";const{utils:n,writeFile:h}=a,i="excel-list.xlsx";function S({data:x,header:t,filename:o=i,json2sheetOpts:s={},write2excelOpts:e={bookType:"xlsx"}}){const r=[...x];t&&(r.unshift(t),s.skipHeader=!0);const c=n.json_to_sheet(r,s),k={SheetNames:[o],Sheets:{[o]:c}};h(k,o,e)}function _({data:x,header:t,filename:o=i,write2excelOpts:s={bookType:"xlsx"}}){const e=[...x];t&&e.unshift(t);const r=n.aoa_to_sheet(e),c={SheetNames:[o],Sheets:{[o]:r}};h(c,o,s)}export{_ as aoaToSheetXlsx,S as jsonToSheetXlsx};