ImportSpreadsheetConfig
ImportSpreadsheetConfig:
{}Options for DocAuthSystem.importSpreadsheet.
Experimental: the spreadsheet API may change or be removed in any release, including minor and patch releases.
Examples
Section titled “Examples”// Everything is optional; the content decides the format and the name only breaks tiesconst spreadsheet = await system.importSpreadsheet(blob, { fileName: 'quarterly.xlsx' });// Progress and cancellation together. Progress is per phase: `done` and `total` start again when it changes.const controller = new AbortController();const spreadsheet = await system.importSpreadsheet(file, { abortSignal: controller.signal,});Properties
Section titled “Properties”fileName?
Section titled “fileName?”
readonlyoptionalfileName:string
A hint for detection when the content is ambiguous. The content decides; the name breaks ties.
format?
Section titled “format?”
readonlyoptionalformat:SpreadsheetImportFileFormat
The format to read. The content is checked against it.
abortSignal?
Section titled “abortSignal?”
readonlyoptionalabortSignal:AbortSignal
Aborts the import. A cancelled import rejects; it never resolves with a partly-read spreadsheet.
onProgress()?
Section titled “onProgress()?”
readonlyoptionalonProgress: (progress) =>void
Called while the spreadsheet opens, at most about ten times a second.
Not called at all for a file small enough to be read in one step, which covers most spreadsheets — so treat its absence as “still working”, not as “nothing is happening”, and show something of your own from the moment the import starts. An exception thrown from here does not fail the import.