pdf-creator-node
pdf-creator-node copied to clipboard
Does not have option for file name.
Hello
I am trying to add option filename but it takes full path as file name. But I want to add custom file name to pdf. How can I change?
Please help me. Its very urgent
use path in create()
first parameter.
var options = { format: "A4", orientation: "portrait" }
var document = {
html: fs.readFileSync(__dirname + "/index.html", "utf8"),
data: { title: "d" },
path: folder_path + "xyz.pdf",
}
pdf.create(document, options)