Load file from local disk

On this page

When the source file is located on the local disk, GroupDocs.Comparison allows you to load it using the Comparer class constructor by specifying an absolute or relative path. To load the target file located on the local disk, use the add() method. Specify an absolute or relative path as the parameter.

The following code snippet shows how to load files from a local disk:

const comparer = new groupdocs.comparison.Comparer(sourcePdfPath);
comparer.add(targetPdfPath);
const resultPath = comparer.compare(resultPdfPath);

On this page