UNPKG

office-text-extractor

Version:

Yet another library to extract text from MS Office and PDF files

7 lines (6 loc) 284 B
// source/util.ts // Utility functions to help with the handling of input. import { readFile as read } from 'node:fs/promises'; import { got as fetch } from 'got'; export const readFile = async (filePath) => read(filePath); export const fetchUrl = async (url) => fetch(url).buffer();