-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
undefined for invoice.getInvoice().toPDF().toBuffer() #45
Comments
Oh! Can you create a PR to fix that ? |
sure @rimiti will do. One more question is there any option to update |
below generates the buffer, please tell me in which file do you want me to place this code?
|
What about fix? |
Fix please src/generator.js
Should be replaced to
|
Thanks for you contribution. It has been released. 🙏 |
unable to create buffer
`const invoiceIt = require('@rimiti/invoice-it').default;
const recipient = {
company_name: 'Receiver company',
first_name: 'Will',
last_name: 'Jameson',
street_number: '20',
street_name: 'Rue Victor Hugo',
zip_code: '77340',
city: 'Pontault-Combault',
country: 'France',
phone: '06 00 00 00 00',
mail: '[email protected]'
};
const emitter = {
name: 'Dim Solution',
street_number: '15',
street_name: 'Rue Jean Jaures',
zip_code: '75012',
city: 'Paris',
country: 'France',
phone: '01 00 00 00 00',
mail: '[email protected]',
website: 'www.dimsolution.com'
};
const invoice = invoiceIt.create(recipient, emitter);
const pdf = invoice.getInvoice().toPDF().toBuffer()
const pdf = invoice.getInvoice().toPDF()
// .toFile('./invoice.pdf')
// .then((r) => {
// console.log('PDF file created.',r);
// });
console.log(pdf)`
The text was updated successfully, but these errors were encountered: