The fjson file should keep the "display_toc" option
javiereguiluz opened this issue · 3 comments
javiereguiluz commented
In the *.fjson files generated by Sphinx, there's a boolean option called display_toc. Sphinx explains it as follows:
display_toc
A boolean that is True if the toc contains more than one entry.
Source: https://www.sphinx-doc.org/en/1.0/builders.html#serialization-builder-details
This is used in some parts of Symfony to decide if the TOC is displayed or not. So we should probably keep it for compatibility. Thanks!
fabpot commented
Actually, now that toc is an array and not an HTML snippet, we don't need the display_toc anymore as we do have the information via toc directly.
javiereguiluz commented
Great. Let's close then. Thanks!
fabpot commented
Migration path: page.display_toc to page.toc|length > 1