xuri / excelize-wasm

A WebAssembly build of the Go Excelize library for reading and writing Microsoft Excel™ (XLAM / XLSM / XLSX / XLTM / XLTX) spreadsheets
https://xuri.me/excelize
BSD 3-Clause "New" or "Revised" License
190 stars 33 forks source link

Argument type Buffer is not assignable to parameter type Uint8Array[] #11

Closed zhuweiyou closed 1 year ago

zhuweiyou commented 1 year ago
const { readFile } = require('fs/promises')

excelize.OpenReader(await readFile('./file.xlsx'))

Why is the first parameter of OpenReader() Uint8Array[] instead of Uint8Array ?

Argument type Buffer is not assignable to parameter type Uint8Array[]

https://github.com/xuri/excelize-wasm/blob/e9ceb7490521d5bb22a47696fb964239235ddb0f/src/index.d.ts#L901-L909

xuri commented 1 year ago

Thanks for your issue. I have fixed this issue, and this patch will be released in the next version.