-
-
Notifications
You must be signed in to change notification settings - Fork 9
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
[RFC]: add support for exporting API docs to a PDF #30
Comments
Alternatively, could use pdfmake in combination with html-to-pdfmake, which I have been using with some success. |
Yeah, my sense is that anything HTML-to-PDF will be tricky/imperfect given our heavy reliance on CSS, and that a more robust conversion pipeline over the long term would be JSON-to-TeX. |
While not getting us near the ability to export the entire docs as a PDF document, I tweaked our CSS a bit per 8eec861 to allow one to nicely print the current README.md from the docs website without any interface elements. |
Here is an example: We could consider having additional elements that are only visible when printing, e.g. some attribution / date of export. What do you think? |
Also a added a button to print the currently selected Dark theme:Light theme: |
Yeah, adding a copyright notice might be one thing to add, along with the date of export. |
And maybe the version of the docs for which the |
Yeah, that makes sense, as well. |
Description
This RFC proposes adding support for exporting API docs to a PDF.
PDF documentation could be useful outside of the website and in the context of offline usage. PDF docs are common in, e.g., R and TeX documentation.
Generation of the PDF could be done either on-demand (client side; see htm2pdf.js) or pre-compiled on the server and simply sent on request.
HTML to PDF can be problematic, as a common technique is to capture HTML as an image, which prevents the generated PDF text from being searchable or selectable.
This RFC would benefit from gh-27, where JSON could be used to automatically generate TeX which could then be compiled to a PDF.
Related Issues
Related issues #27.
Questions
No.
Other
No.
Checklist
RFC:
.The text was updated successfully, but these errors were encountered: