codimd
codimd copied to clipboard
WIP: Export PDF with puppeteer
It takes about 5 seconds to print a pdf now... quite slow.
TODO
- [ ] Better download experience
- [ ] Is this safe?
- [ ]
NPM_CONFIG_PRODUCTIONtrue
Heroku image is too big when building with puppeteer buildpack
- https://github.com/jontewks/puppeteer-heroku-buildpack
- https://github.com/CoffeeAndCode/puppeteer-heroku-buildpack
I'll try to move all webpack build dependency into devDependency, then let heroku remove them automatically.
-----> Compressing...
! Compiled slug size: 612.6M is too large (max is 500M).
! See: http://devcenter.heroku.com/articles/slug-size
! Push failed
https://devcenter.heroku.com/articles/slug-compiler#slug-size
-----> Compressing...
! Compiled slug size: 520.4M is too large (max is 500M).
! See: http://devcenter.heroku.com/articles/slug-size
! Push failed
well, well 😂
Procfile declares types -> web
-----> Compressing...
Done: 493.6M
-----> Launching...
! Warning: Your slug size (493 MB) exceeds our soft limit (300 MB) which may affect boot time.
Released v10
https://codimd-feature-pdf-expo-las27r.herokuapp.com/ deployed to Heroku