Live data from Hacker News

I don't always use LaTeX, but when I do, I compile to HTML (2013)

peterkrautzberger.org

11–20 of 152 posts

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#11

Sphinx and reStructuredText are, IMHO, underrated power houses of document building. With extensions, you can hook them up to Zotero (or whatever)-managed bibtex files. You can render to beautiful HTML files, and you get latex PDFs and epubs for free. First class latex-math support, plenty of integrations with things like mermaid, graphviz, and the ability to build super-powerful custom directives to do basically any…

One of the selling points of PDF is that it is a single self-contained file. I found this lacking in Sphinx and wrote an extension for it to zip and bundle the assets into a single HTML file: https://github.com/AdrianVollmer/Zundler

Also works with HTML documents produced in other ways.

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#12
post #11

Sphinx and reStructuredText are, IMHO, underrated power houses of document building. With extensions, you can hook them up to Zotero (or whatever)-managed bibtex files. You can render to beautiful HTML files, and you get latex PDFs and epubs for free. First class latex-math support, plenty of integrations with things like mermaid, graphviz, and the ability to build super-powerful custom directives to do basically any…

One of the selling points of PDF is that it is a single self-contained file. I found this lacking in Sphinx and wrote an extension for it to zip and bundle the assets into a single HTML file: https://github.com/AdrianVollmer/Zundler Also works with HTML documents produced in other ways.

Hmm, the disadvantage of your approach is that it unconditionally requires Javascript, even if the original didn't.

Also if you're going to embed a giant binary blob, please ship way to extract it.

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#13
post #12
post #11

Earlier quoted context omitted.

One of the selling points of PDF is that it is a single self-contained file. I found this lacking in Sphinx and wrote an extension for it to zip and bundle the assets into a single HTML file: https://github.com/AdrianVollmer/Zundler Also works with HTML documents produced in other ways.

Hmm, the disadvantage of your approach is that it unconditionally requires Javascript, even if the original didn't. Also if you're going to embed a giant binary blob, please ship way to extract it.

Yes, it's a trade-off.

Not a bad idea, thanks for the suggestion.

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#14
This is from 2013, so the bet that "nobody will want to read [PDFs] in 5 years" can be considered failed. If anything, PDF has become the lingua franca of the academic web, crowding out even DjVU at the thing that DjVU was made for and PDF was not.

I have not been following the development of mathjax, pandoc, etc. carefully, so I'm wondering: Have the main issues been solved? By these I mean

(1) support for most popular packages,

(2) automatically breaking long outputs into small pages that don't overheat my laptop or crash my browser and yet reference each other properly,

(3) printability (without lines broken in half, senseless overflows and the likes) or cross-compilability with a regular PDF compiler?

I know the ar5iv project is getting closer and closer to (1) and (3), but is that available to regular users?

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#17
post #11

Sphinx and reStructuredText are, IMHO, underrated power houses of document building. With extensions, you can hook them up to Zotero (or whatever)-managed bibtex files. You can render to beautiful HTML files, and you get latex PDFs and epubs for free. First class latex-math support, plenty of integrations with things like mermaid, graphviz, and the ability to build super-powerful custom directives to do basically any…

One of the selling points of PDF is that it is a single self-contained file. I found this lacking in Sphinx and wrote an extension for it to zip and bundle the assets into a single HTML file: https://github.com/AdrianVollmer/Zundler Also works with HTML documents produced in other ways.

You're getting close to making your own CHM format, which Sphinx could make for you.

I always thought CHM files were a nice self-contained option for multi-page HTML docs. (Though they'd happily execute whatever JavaScript the author embedded in there... Maybe that's why they fell out favor?)

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#18
post #11

Earlier quoted context omitted.

One of the selling points of PDF is that it is a single self-contained file. I found this lacking in Sphinx and wrote an extension for it to zip and bundle the assets into a single HTML file: https://github.com/AdrianVollmer/Zundler Also works with HTML documents produced in other ways.

You're getting close to making your own CHM format, which Sphinx could make for you. I always thought CHM files were a nice self-contained option for multi-page HTML docs. (Though they'd happily execute whatever JavaScript the author embedded in there... Maybe that's why they fell out favor?)

It would be great if there was an open CHM-like format that was supported by all major browsers. The nice thing about browsers is that everyone already got one installed. They can even open PDFs natively these days. Sadly, they cannot even open epubs (which is almost like CHM without interactivity). I believe firefox used to be able to open epubs, not sure what happened.

Re: I don't always use LaTeX, but when I do, I compile to HTML (2013)

#20

This is from 2013, so the bet that "nobody will want to read [PDFs] in 5 years" can be considered failed. If anything, PDF has become the lingua franca of the academic web, crowding out even DjVU at the thing that DjVU was made for and PDF was not. I have not been following the development of mathjax, pandoc, etc. carefully, so I'm wondering: Have the main issues been solved? By these I mean (1) support for most popu…

And it is a shame. The current AI explosion is the poorer for it, due to the greater difficulty of extracting the text from PDFs.
Post reply on HN