using npm pkg instead of cdn url for jszip and reducing batch size

This commit is contained in:
2026-05-12 19:00:28 +02:00
parent 173f9f9e56
commit c74f11794d
4 changed files with 191 additions and 4 deletions

View File

@@ -1483,14 +1483,14 @@
};
// Download in batches to avoid overwhelming the browser/server
const batchSize = 5;
const batchSize = 3;
for (let i = 0; i < filesToDownload.length; i += batchSize) {
const batch = filesToDownload.slice(i, i + batchSize);
await Promise.all(batch.map(downloadFile));
}
exportStatusText.textContent = 'Generating ZIP file...';
const content = await zip.generateAsync({ type: 'blob' });
const content = await zip.generateAsync({ type: 'blob', streamFiles: true });
const link = document.createElement('a');
link.href = URL.createObjectURL(content);