Skip to content

Commit 429e196

Browse files
committed
remove the node version
1 parent 60877b6 commit 429e196

File tree

3 files changed

+0
-290
lines changed

3 files changed

+0
-290
lines changed

README.md

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -31,27 +31,3 @@ Turn two PDFs into one large PNG image showing the differences:
3131

3232
python3 pdf-diff.py before.pdf after.pdf > test.png
3333

34-
35-
Node Version
36-
------------
37-
38-
There's also a node.js version for computing the changes that uses Mozilla's pdf.js instead of `pdftotext`. Getting pdf.js to work in node.js isn't straightforward:
39-
40-
npm install
41-
42-
git clone https://github.com/mozilla/pdf.js
43-
cd pdf.js
44-
node make singlefile
45-
cd ..
46-
47-
Compute the changes (writes a JSON file):
48-
49-
node index.js before.pdf after.pdf | grep -v "^Warning:" > changes.json
50-
51-
(Unfortunately the pdf.js library prints warnings on STDOUT, so we have to filter those out.)
52-
53-
Render the changes:
54-
55-
python3 pdf-diff.py --changes < changes.json > test.png
56-
57-
`pdftotext` gives bounding boxes for each word in the document while pdf.js only gives bounding boxes for text runs, so the granularity is not as good.

index.js

Lines changed: 0 additions & 246 deletions
This file was deleted.

package.json

Lines changed: 0 additions & 20 deletions
This file was deleted.

0 commit comments

Comments
 (0)