From eec4bc90efd0c4700e0ebf8f279a646023d1f93f Mon Sep 17 00:00:00 2001 From: Rand McKinney Date: Fri, 17 Apr 2026 12:57:07 -0700 Subject: [PATCH] Add meta tags to API docs --- api-docs/conf.py | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/api-docs/conf.py b/api-docs/conf.py index bc1afbc7..9bb4b30a 100644 --- a/api-docs/conf.py +++ b/api-docs/conf.py @@ -61,4 +61,27 @@ napoleon_google_docstring = True napoleon_numpy_docstring = False +# -- Global HTML meta tags --------------------------------------------------- + +# Inject extra tags into the of every generated HTML page, +# regardless of source format (.rst, .md, AutoAPI-generated, etc.). +html_meta_tags = [ + {"name": "algolia-site-verification", "content": "EA363696C40197CA"}, +] + + +def _add_html_meta_tags(app, pagename, templatename, context, doctree): + rendered = "".join( + "\n" + for tag in html_meta_tags + ) + context["metatags"] = context.get("metatags", "") + rendered + + +def setup(app): + app.connect("html-page-context", _add_html_meta_tags) + return {"parallel_read_safe": True, "parallel_write_safe": True} +