Large files
How AnyPreview keeps 500-page PDFs, 100,000-row spreadsheets, million-row CSVs and huge logs fast, with workers and windowed rendering.
| What | How |
|---|---|
| Office, OpenDocument and CSV files of 512 KB and up | Parsed in a Web Worker (workers, on by default), so the page stays responsive while they load. If the worker cannot start, parsing falls back to the main thread. |
| Only pages near the view are drawn; far pages release their memory. Search uses a background text index. | |
| Excel sheets over 2,000 rows | Rows are windowed in blocks that never split a merge; sheet XML is streamed instead of built into a tree. |
| CSV over 1,000 rows | Windowed rows with fixed column widths, up to a million rows. |
| Text over 3,000 lines | Windowed blocks of lines, with line numbers, search and print over the whole file. |
| Word and PowerPoint | Pages and slides off screen skip layout and paint (content-visibility). |
Measured on the samples in our repository (a 100,000-row workbook): browser memory went from 521 MB to 188 MB with streaming, and the longest main-thread task from 0.79 s to 0.23 s with the worker.
Use maxBytes to refuse files you do not want to open at all.