Remix.run Logo
collabs 8 hours ago

I'm sure everyone has their own use case but I use typst for resumes or other documents that I want to keep in git but I need to share with others using PDF.

I use typst in visual studio code using tiny mist extension. I can generate PDF without installing any new software other than vscode which I already have and the tiny mist extension. The live preview is also nice.

The one thing that bothers me is the dollar sign and the hash sign so to write something like saved $50 million using c#, I write something like saved USD 50 million using #csharp

And near the top I add a variable like this

  #let csharp = "C#"
seanclayton 7 hours ago | parent [-]

Markdown has the same class of issue and resolves it the same way you would with Typst: The escape character \. You instead write saved \$50 million using C\#.

runarberg 4 hours ago | parent [-]

I never understood why markdown authors are so insistent on using a single $ to denote math. Math is outside the commonmark spec so this is entirely up to plugin authors.

I am an author of a fairly popular (and early) math plugin for markdown and I resisted (albeit not very hard). I made $$ the default delimiter but I noticed very soon that my users hated it, and finally I gave up and made $ the default delimiter.

What I would have preferred is for $ to behave exactly like backticks (except a minimum of two to start inline math) So you could do stuff like $$ f $ x $$ to render f $ x meaning function f applied with x. And write stuff like:

    $$$optional-tag
    f $ x
    $$$
for block math. I even wrote a competing plugin to my older one where I do this, but I don‘t think anybody uses is, because most people writing math in markdown are expecting it to behave exactly like latex.
paradox460 4 hours ago | parent [-]

I personally like using code blocks with math as the language

Gives you a nice, block level element, and it's easy to reason about

runarberg 4 hours ago | parent [-]

I don’t really like that either since code blocks are supposed to be verbatim, and the language is only supposed to be a hint for syntax highlighting. Additionally you also occupy the first tag which may be an issue when e.g. writing a preample for a latex renderer (or if you want to pick a different renderer).