adonis-pdf
Advanced tools
Comparing version 0.0.20 to 0.0.21
{ | ||
"name": "adonis-pdf", | ||
"version": "0.0.20", | ||
"version": "0.0.21", | ||
"description": "Create PDF files within Adonis using pdfmake", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -33,3 +33,3 @@ # adonis-pdf | ||
* `definition`: Object representing the PDF content/styles etc | ||
* `content`: Array representing the PDF content | ||
* `stream`: A Readable or Writeable Stream the PDF will be piped to | ||
@@ -47,18 +47,7 @@ | ||
const definition = { | ||
content: [ | ||
{ | ||
text: 'test', | ||
style: 'header' | ||
} | ||
], | ||
styles: { | ||
header: { | ||
fontSize: 22, | ||
bold: true | ||
} | ||
} | ||
} | ||
const content = [ | ||
{ text: 'test' } | ||
] | ||
PDF.create(definition, response.response) | ||
PDF.create(content, response.response) | ||
@@ -65,0 +54,0 @@ return response |
2146108
59