0

Let's assume two reStructuredText files in same Sphinx project. Files are located on the same directory.
One of them -foo.rst contains section bar, like:

bar
===
some items...

How do I link to bar anchor in another *.rst document?

mzjn
  • 48,958
  • 13
  • 128
  • 248
Juhas
  • 178
  • 2
  • 13
  • 1
    See https://stackoverflow.com/q/4385315/407651 – mzjn Jul 21 '22 at 10:00
  • Thanks for the link - it gave me an idea where I did wrong. Testing and will update. – Juhas Jul 21 '22 at 10:10
  • 1
    Even more answers here: https://stackoverflow.com/q/15394347/407651 – mzjn Jul 21 '22 at 10:35
  • This question shall be closed - answers contained in https://stackoverflow.com/q/15394347/407651. Briefly - add extension `autosectionlabel`, but section names couldn't be doubled then and sphinx will raise warnings when compiling. The second (workaround) is to add `.. _foo:` in document which have to be linked. – Juhas Jul 21 '22 at 10:58

0 Answers0