-
-
Notifications
You must be signed in to change notification settings - Fork 32
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
Incompatible with PDF exporting #12
Comments
Hi @jessejoe! Thanks for the detailed issue. The adoption of Microbundle must have indeed broken compatibility with resume-cli. The By the way, I'd highly recommend giving Resumed a try, as it's a more modern alternative to resume-cli with better theme handling, albeit with fewer features, like no PDF exporting—which I don't think should be the tool's responsibility anyway. You can also directly use the theme to generate your HTML resume. As for the printing gaps and breaks, it's extremely difficult to ensure a continuous page is perfectly converted into discrete ones, considering all the different page sizes, margins, renderers (e.g. Chrome vs Firefox), as well as the content itself. Fixing one issue (e.g. adding page breaks to avoid cut-off text) unfortunately leads to another (huge gaps between sections). What I usually do is manually fiddle with print settings (margins, scale, etc) until the result looks good 🤷♂️ |
Thanks @rbardini! Yep, been using Yeah, I know CSS is a PITA. One thing to mention is I don't see the issue with the |
I think that's because browsers have some trouble printing CSS grid–based layouts. You could try v0.3.2 and see how it goes? Won't look as pretty but might behave better as a PDF 🙂 |
@jessejoe I just added some examples to the Resumed repository, including one with PDF exporting. You can play with Puppeteer's options and see if it gives a better result. |
Hey @rbardini, sorry for the delay. Thanks for creating those! Unfortunately, I don't personally see any improvement over using browsers to export (not sure if it was intended?). I also notice some of the rendering that is visible in the PDF is missing when you print the PDF, so I wouldn't really use it, though I guess it is nice to have an option for PDF export with puppeteer inside the repo. |
Sadly, printing with a browser or Puppeteer will bring similar results, as this is a CSS grid rendering issue. I guess the only workaround is to use an older theme version that doesn't use grid layout (v0.3.2 or below). I may have to revert back to flow layout because of this, which is a shame 😢 The examples are mostly to help resume-cli users migrate to Resumed, which should have fewer theme compatibility issues. |
Makes sense. The only reason I use JSON resume in the first place is so I can export in HTML and PDF. If PDF doesn't work, then it defeats the usefulness of the whole thing IMO. |
Summary
There are 2 issues with PDF export:
resume-cli
PDF export - which looks to be because of changes inv0.14.0
which changed the package layout and removedindex.js
1.
resume-cli
incompatibilityCurrent version is incompatible with
resume-cli
PDF export:The code for
resume-cli
seems to be looking forindex.js
, which no longer exists.Downgrading to
v0.13.0
(which still containedindex.js
) works:I believe the changes to use
microbundle
inv0.14.0
may have broken this.2. CSS elements cut off or huge gaps
When printing the exported resume HTML using Chrome, elements can be split over page breaks:
In Firefox, it seems to want to keep entire sections together, so leaves huge breaks between:
I assume this needs some changes to to print media CSS, however that's not my expertise.
The text was updated successfully, but these errors were encountered: