Function to split a PDF file by page ranges and merge them into a new MwFile
MwFile object
An array of page ranges to extract, each range is an array with two numbers: the start and end page numbers
An MwFile object with only the extracted page ranges from the original file
const mwFile = convertBase64ToFile(examplePdfBase64);const ranges = [[0, 2], [4, 5], [7, 8]];const newMwFile = await pdfExtractRanges(mwFile, ranges); Copy
const mwFile = convertBase64ToFile(examplePdfBase64);const ranges = [[0, 2], [4, 5], [7, 8]];const newMwFile = await pdfExtractRanges(mwFile, ranges);
Function to split a PDF file by page ranges and merge them into a new MwFile