File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed
Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change 1+ {#
2+ Adds a canonical link to the stable version of the documentation to each built hmtl page.
3+ The reason to do that is that search engines require it:
4+ https://developers.google.com/search/docs/crawling-indexing/consolidate-duplicate-urls
5+
6+ This template overrides the page.html furo template
7+ (https://github.com/pradyunsg/furo/blob/main/src/furo/theme/furo/page.html) by adding an extra
8+ line to its < head > section, with the appropriate canonical link. Note that there is no guarantee
9+ that the furo theme keeps using a file named page.html, so this could silently break with future
10+ updates of furo. See https://pradyunsg.me/furo/customisation/injecting/ and
11+ https://github.com/pradyunsg/furo/discussions/248 for more information.
12+ #}
13+ {% extends "!page.html" %}
14+ {% block extrahead %}
15+ < link rel ="canonical " href ="https://torchjd.org/stable/{{ pagename }}.html ">
16+ {% endblock %}
Original file line number Diff line number Diff line change 4444
4545html_theme = "furo"
4646html_static_path = ["_static" ]
47+ templates_path = ["_templates" ]
4748
4849autodoc_member_order = "bysource"
4950intersphinx_mapping = {
You can’t perform that action at this time.
0 commit comments