Buffer is required as it was originally there too
This commit is contained in:
@ -46,7 +46,7 @@ export interface IDocumentTemplate {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export class ImportDotx {
|
export class ImportDotx {
|
||||||
public async extract(data: string | number[] | Uint8Array | ArrayBuffer | Blob | NodeJS.ReadableStream): Promise<IDocumentTemplate> {
|
public async extract(data: Buffer | string | number[] | Uint8Array | ArrayBuffer | Blob | NodeJS.ReadableStream): Promise<IDocumentTemplate> {
|
||||||
const zipContent = await JSZip.loadAsync(data);
|
const zipContent = await JSZip.loadAsync(data);
|
||||||
|
|
||||||
const documentContent = await zipContent.files["word/document.xml"].async("text");
|
const documentContent = await zipContent.files["word/document.xml"].async("text");
|
||||||
|
Reference in New Issue
Block a user