Skip to content

Commit

Permalink
Fix setting of hidden_methods template variable (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
hagenw authored Jan 10, 2024
1 parent cf2b09c commit 8a83439
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions sphinx_apipages/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,6 @@ def setup(app: sphinx.application.Sphinx):
# https://github.com/sphinx-doc/sphinx/issues/6316
app.config.toc_object_entries = False

# Make apipages_hidden_methods visible in templates
app.config.autosummary_context = {
"hidden_methods": app.config.apipages_hidden_methods,
}

# Connect events
app.connect("config-inited", config_inited)

Expand All @@ -71,6 +66,11 @@ def config_inited(app: sphinx.application.Sphinx, config):
else:
app.config.templates_path = templates_path

# Make apipages_hidden_methods visible in templates
app.config.autosummary_context = {
"hidden_methods": app.config.apipages_hidden_methods,
}

# Copy API (sub-)module RST files to dst folder
if os.path.exists(src_dir):
audeer.mkdir(dst_dir)
Expand Down

0 comments on commit 8a83439

Please sign in to comment.