Writing option "type" not documented #432

Closed
opened 2016-06-29 20:15:22 +00:00 by tomkel · 1 comment
tomkel commented 2016-06-29 20:15:22 +00:00 (Migrated from github.com)

One of the options that is necessary when using xslx.write is the type option. According to the function write_zip_type, it must be set to base64, binary, buffer, or file, or else an error is thrown.

One of the options that is necessary when using `xslx.write` is the `type` option. According to the function `write_zip_type`, it must be set to `base64`, `binary`, `buffer`, or `file`, or else an error is thrown.
reviewher commented 2017-02-21 21:30:43 +00:00 (Migrated from github.com)

@tomkel you're right, it should be included in https://github.com/SheetJS/js-xlsx/#writing-options. The possible values mirror the read functions and are listed in another issue: https://github.com/SheetJS/js-xlsx/issues/337#issuecomment-281284479

type expected input
"base64" string: base64 encoding of the file
"binary" string: binary encoded string (the n-th byte is data.charCodeAt(n))
"buffer" nodejs Buffer
"file" string: filename that will be written and processed (nodejs only)

@SheetJSDev that table should be copied into the README

@tomkel you're right, it should be included in https://github.com/SheetJS/js-xlsx/#writing-options. The possible values mirror the read functions and are listed in another issue: https://github.com/SheetJS/js-xlsx/issues/337#issuecomment-281284479 | `type` | expected input | |------------|--------------------------------------------------------------------------| | `"base64"` | string: base64 encoding of the file | | `"binary"` | string: binary encoded string (the `n`-th byte is `data.charCodeAt(n)`) | | `"buffer"` | nodejs Buffer | | `"file"` | string: filename that will be written and processed (nodejs only) | @SheetJSDev that table should be copied into the README
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: sheetjs/sheetjs#432
No description provided.