JuliaBooks / Books.jl

Create books with Julia
https://huijzer.xyz/Books.jl/
Other
269 stars 18 forks source link

Math reference error #300

Open henry2004y opened 2 years ago

henry2004y commented 2 years ago

Hi,

The syntax for labeling math is

$$
1 + 1 = 2
$$ {#eq:math}

and the syntax for referencing is @eq:math. This works fine in a single section, but a reference to a equation in another section doesn't work. This can be seen from the urls where references work by appending the label to the section like http://localhost:8004/page1.html#eq:math, where page1 seems to be always the same section as the current one.

I am not sure if references to figures/tables have the same issues.

rikhuijzer commented 2 years ago

Aah yes. That's a bug. What happens is that Pandoc "sees" the whole website as one big document and generates references and such for that. Next, Books.jl splits this up in separate pages and, hence, changes a lot of links such as references and sections. Apparently, it doesn't fix equations yet. Unfortunately, I don't expect to have time to fix this anytime soon. Hopefully, you or someone else will find this a nice problem to fix.

henry2004y commented 2 years ago

It's not urgent. I simply record the issue here and may come back to fix it.