Is there a way to define a "base theme"? #45
-
In kedro-org/kedro#3016 we're thinking of creating a Sphinx theme that derives from Does |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Hi there! This is certainly doable. https://github.com/executablebooks/sphinx-book-theme/blob/master/src/sphinx_book_theme/theme/sphinx_book_theme/theme.conf#L2 is the information that Sphinx's templating engine AKA theme system needs to have. Other than that, add a runtime dependency on it via project.dependencies and you should be good. The derived theme can override specific templates as well as do a bunch of other stuff as it is a full Sphinx extension too. The parent theme is also loaded as an extension, IIRC. |
Beta Was this translation helpful? Give feedback.
Hi there! This is certainly doable.
https://github.com/executablebooks/sphinx-book-theme/blob/master/src/sphinx_book_theme/theme/sphinx_book_theme/theme.conf#L2 is the information that Sphinx's templating engine AKA theme system needs to have.
Other than that, add a runtime dependency on it via project.dependencies and you should be good.
The derived theme can override specific templates as well as do a bunch of other stuff as it is a full Sphinx extension too. The parent theme is also loaded as an extension, IIRC.