mergeMultiplePDFs method
Merges multiple PDFs into one PDF.
Takes a list of input file paths and an output path, and returns the path of the merged PDF as a string.
inputPaths
- List of paths to the input PDF files.
outputPath
- The path where the merged PDF will be saved.
Implementation
@override
Future<String> mergeMultiplePDFs({
required List<String> inputPaths,
required String outputPath,
}) async {
final JSArray<JSString> jsInputPaths = inputPaths.toJSArray();
final JSString result =
(await combinePDFs(jsInputPaths).toDart) as JSString;
return result.toDart;
}