node-wkhtml
node-wkhtml copied to clipboard
[feature demand]"add" function works on html type
currently , PDF.add works only on url and file type, but it doesn't work on html type:
pdf = new PDF({
html:"html content 1"
});
pdf.add({
html:"html content 2"
});
it will generate:
echo 'html content 2' | wkhtmltopdf - -
then throw an error: Command failed: Loading pages (1/6).
I'm not very familiar on stdin :(
Yeah, this is really tricky. I'm not all that familiar with stdin either. I tried to get this feature to work, but unfortunately I can only seem to pipe in one input stream.
I'll leave this issue open. For now, concatenating the HTML beforehand is probably the best choice. If you need page breaks, CSS does support page break hints that webkit will honor.