@root-kings/pdf-generator
v1.0.0
Published
You need to install `wkhtmltopdf` from [https://wkhtmltopdf.org/downloads.html#stable](https://wkhtmltopdf.org/downloads.html#stable)
Downloads
2
Readme
pdf-generator
You need to install wkhtmltopdf
from https://wkhtmltopdf.org/downloads.html#stable
Usage
npm i @root-kings/pdf-generator
const generatePDF = require('@root-kings/pdf-generator')
let outputPath = await generatePDF(templateName, data)
let outputPath = await generatePDF(templateData, data)
let outputPath = await generatePDF(template, data, outputFilePath)
Examples
Please check tests/index.js
.
TODO
- [ ] Error Handling
- [ ] Add validation