Live data from Hacker News

Show HN: TeXbrain, a LaTeX editor that runs pdfTeX in the browser via WASM

github.com

21–30 of 32 posts

Re: Show HN: TeXbrain, a LaTeX editor that runs pdfTeX in the browser via WASM

#21

Anyone know if this includes TikZ?

Yes, tikz.sty, pgf.sty and pgfplots.sty are in the bundled subset (it's around 360 pgf related files that ship with the app). Only the graph drawing sublibrary requires LuaTeX, so that one won't work.

Re: Show HN: TeXbrain, a LaTeX editor that runs pdfTeX in the browser via WASM

#23
post #6

I copy-pasted a random LaTeX doc from many years ago (I made sure I wrote it before 2020 so it did not use any new features not in TeX Live 2020), and upon compilation I got the error Font OT1/cmr/m/n/10.95=cmr10 at 10.95pt not loadable: Bad metric (TFM) file. on line 13017. The document had only 200 lines so this must be from a package. It was really not clear where the error was coming from. I guessed that it was c…

Can't tell much from those two lines, but if you open an issue with the document, or just provide the full compile log, I could dig into it.

The TFM error usually means a font file wasn't available. However, the service worker validates the downloads before caching, so any error pages or empty bodies get rejected (which makes posoned cache unlikely), but a stale state may still be possible.

Hard refresh bypasses the service worker, I patched around that last month but apparently not well enough.

Also, better error logs and reporting is already on my ToDo-list, sorry for that.

Re: Show HN: TeXbrain, a LaTeX editor that runs pdfTeX in the browser via WASM

#27
post #6

I copy-pasted a random LaTeX doc from many years ago (I made sure I wrote it before 2020 so it did not use any new features not in TeX Live 2020), and upon compilation I got the error Font OT1/cmr/m/n/10.95=cmr10 at 10.95pt not loadable: Bad metric (TFM) file. on line 13017. The document had only 200 lines so this must be from a package. It was really not clear where the error was coming from. I guessed that it was c…

Can't tell much from those two lines, but if you open an issue with the document, or just provide the full compile log, I could dig into it. The TFM error usually means a font file wasn't available. However, the service worker validates the downloads before caching, so any error pages or empty bodies get rejected (which makes posoned cache unlikely), but a stale state may still be possible. Hard refresh bypasses the…

Where is the full compile log? The UI seems to provide a very abbreviated log that’s clearly not full.

Re: Show HN: TeXbrain, a LaTeX editor that runs pdfTeX in the browser via WASM

#28
Awesome! I was looking for something like this, and I thought I've got it with Crixet (now OpenAI Prism). I had to compile a rather heavy presentation template and Overleaf would simply time-out, Crixet being client based was the only option.

Great to see a FOSS version!

Re: Show HN: TeXbrain, a LaTeX editor that runs pdfTeX in the browser via WASM

#29

Usability to see changes live is a bit weird. Ctrl+S brings up the browser save as but also saves the document and recompiles. Ctrl+Enter puts in a new line and recompiles. Can click compile of course, but that's not efficient.

Fair points, Ctrl+Enter was also CodeMirror's "insert empty line" and Ctrl+S won the welcome file went through "save as", since that document has no existing file yet. It's fixed now.

It compiles on its own a second after you stop typing, and there's also an "Auto" button next to "Compile" if you prefer to press Ctrl+Enter yourself.

Post reply on HN