From 09559b6a83fe396a2baae1a7652ebffcb556ab5b Mon Sep 17 00:00:00 2001 From: auntieyi Date: Thu, 18 Nov 2021 09:55:43 +0000 Subject: [PATCH] Support add new columns in onDownload When add new columns in onDownload, the download property should be true --- src/utils.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/utils.js b/src/utils.js index 1fe37f748..094f4034b 100644 --- a/src/utils.js +++ b/src/utils.js @@ -88,7 +88,7 @@ function buildCSV(columns, data, options) { soFar + '"' + row.data - .filter((_, index) => columns[index].download) + .filter((_, index) => columns[index] ? columns[index].download : true) .map(columnData => escapeDangerousCSVCharacters(replaceDoubleQuoteInString(columnData))) .join('"' + options.downloadOptions.separator + '"') + '"\r\n',