Skip to content

API / interfaces / writeoptions

Interface: WriteOptions

Options for writing/serializing workbook files

Hierarchy

Extends:

  • CommonOptions

Properties

WTF

optional

WTF: boolean

If true, throw errors on unexpected situations instead of silently recovering

bookVBA

optional

bookVBA: boolean

If true, expose VBA macro data in workbook.vbaraw

cellDates

optional

cellDates: boolean

If true, store dates as Date objects instead of serial numbers

sheetStubs

optional

sheetStubs: boolean

If true, include stub cells for empty cells within the used range

cellStyles

optional

cellStyles: boolean

If true, include style/theme information on cells

password

optional

password: string

Workbook password for encrypted files

type

optional

type: "string" | "base64" | "buffer" | "array"

Output data type: "base64" for base64 string, "buffer" for Node Buffer, "array" for Uint8Array, "string" for plain text

bookType

optional

bookType: "xlsx" | "xlsm" | "csv" | "tsv" | "html"

Output file format (default: "xlsx")

bookSST

optional

bookSST: boolean

If true, generate a Shared Strings Table for string deduplication

compression

optional

compression: boolean

If true, compress (deflate) ZIP entries

themeXLSX

optional

themeXLSX: string

Custom theme XML string to embed

ignoreEC

optional

ignoreEC: boolean

If true, skip error-checking in the output

Props

optional

Props: Properties

File properties to embed in the output

Source

src/types.ts


← WorkSheet