PDF到节点JS上的图像

任何人都知道NodeJS的任何良好的库,甚至一个API来创buildPDF页面的图像?

我认为这个解决scheme应该使用像ghostscript这样的外部程序来构build你的jpg。

var exec = require('child_process').exec; exec('gs -dNOPAUSE -sDEVICE=jpeg -r144 -sOutputFile=p%03d.jpg file.pdf' , function(err) { if (err) { // something went wrong } else { // everything went good do something after the process is completed } });