How to: reference with @
xy9485 opened this issue · comments
I find it's a pleasing experience to write pseudo code with this package.
However, I find myself stuck with how to reference an algorithm using "@".I tried below to label my algorithm but it doesn't work with error: cannot reference sequence
. I label my algorithm with @algo1
as below:
#algo(
title: [ // note that title and parameters
#set text(size: 15pt) // can be content
#emph(smallcaps("Curiosity driven exploration for molecule generation"))
],
parameters: ([#math.italic("n")],),
comment-prefix: [#sym.triangle.stroked.r ],
comment-styles: (fill: rgb(100%, 0%, 0%)),
indent-size: 15pt,
indent-guides: 1pt + gray,
row-gutter: 5pt,
column-gutter: 5pt,
inset: 5pt,
stroke: 2pt + black,
fill: none,
)[
"content of algorithm"
] <algo1>
I'm a beginner of typst, this is what I learned to achieve reference. I'm not sure if it also works with returns of #algo. Otherwise is there any other workaround to refer an algorithm as we do in Latex? I just need at least a basic way to refer my own algorithms.
Please open your issue on the algo repository: https://github.com/platformer/typst-algorithms
Just realized, sorry and thanks for the reference link.