Replies: 2 comments 7 replies
-
Yes, as I understand it the escaping is a limitation of Pandoc in that it processes metadata as markdown. I have places where I need to pass raw Typst code via metadata, and I ended up removing the backslashes and, even worse, running But it works. Best I can suggest is declaring a function to do the unescaping and then it can be done in one line in |
Beta Was this translation helpful? Give feedback.
-
Today, archlinux updated to quarto 1.6.37, My workaround is to declare my own variable, like |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Description
I’ve translated one of my LaTeX extensions to Typst, and while it mostly works, it took a lot of trial and error. My issue revolves around a logo file I export in the
_extensions
folder. When I try to access this file in my Typst template, the underscore in the path is escaped to\_
.I read that this problem can be solved with
object.replace("\\", "")
, which I tried implementing. However, I ended up needing two lines of code to handle the logo path correctly from the YAML header:This seems overly complicated, and I feel like there might be a more efficient way to handle this.
Additionally, my
typst-show.typ
file is almost empty because I’m fetching all YAML parameters directly intypst-template.typ
. My understanding, though, is that all parameters/variables should ideally be defined or manipulated intypst-show.typ
and then made available intypst-template.typ
.A minimal example can be found here: https://github.com/produnis/minimal_examples/tree/typstde
Any suggestions on simplifying the logo path handling or better structuring the YAML parameter usage would be greatly appreciated! :-)
Beta Was this translation helpful? Give feedback.
All reactions