File tree Expand file tree Collapse file tree 2 files changed +13
-10
lines changed
Expand file tree Collapse file tree 2 files changed +13
-10
lines changed Original file line number Diff line number Diff line change @@ -68,12 +68,13 @@ exporter.start()
6868``` javascript
6969app .post (' /pdfexport' , function (req ,res ){
7070 // derive job arguments from request here
71- var job = exporter .createJob (source, target, options)
71+ exporter .createJob (source, target, options). then ( job => {
7272 job .on (' job-complete' , (r ) => {
73- console .log (' pdf files:' , r .results )
74- // Process the PDF file(s) here
75- })
76- job .render ()
73+ console .log (' pdf files:' , r .results )
74+ // Process the PDF file(s) here
75+ })
76+ job .render ()
77+ })
7778})
7879```
7980
Original file line number Diff line number Diff line change 11{
22 "name" : " electron-pdf" ,
3- "version" : " 0.13.1 " ,
3+ "version" : " 1.0.0 " ,
44 "description" : " A command line tool to generate PDF from URL, HTML or Markdown files" ,
55 "main" : " lib/index.js" ,
66 "scripts" : {
2424 " pdf" ,
2525 " png" ,
2626 " export" ,
27- " render"
27+ " render" ,
28+ " html" ,
29+ " markdown"
2830 ],
29- "author" : " Fraser Xu" ,
31+ "author" : " Fraser Xu, Nate Good " ,
3032 "license" : " MIT" ,
3133 "bugs" : {
3234 "url" : " https://github.com/fraserxu/electron-pdf/issues"
4244 "dependencies" : {
4345 "async" : " ^2.0.1" ,
4446 "bluebird" : " ^3.4.6" ,
45- "debug" : " ^2.2.0 " ,
46- "electron" : " ^1.4.3 " ,
47+ "debug" : " ^2.3.2 " ,
48+ "electron" : " ^1.4.6 " ,
4749 "eventemitter2" : " ^2.1.3" ,
4850 "github-markdown-css" : " ^2.0.9" ,
4951 "highlight.js" : " ^9.0.0" ,
You can’t perform that action at this time.
0 commit comments