Let’s make our site a bit more pretty
Add read the docs theme
So just because this is a documentation site and a static site, it does not mean it has to be plain and boring. Sphinx comes with a default theme, called Alabaster.
Who knows, maybe I will stick to that theme in the future, but here, just to try, I’m gonna install a different theme.
You could use one of the built-in themes (https://www.sphinx-doc.org/en/master/usage/theming.html). You can also find the read the docs theme, and install it with pip:
pip install sphinx_rtd_theme
And the you have to add the theme to the extensions in the conf.py file.
extensions = [
...
'sphinx_rtd_theme',
]
html_theme = "sphinx_rtd_theme"
Add a favicon
Because favicons are useless but still make your site look better, let’s add one. I will use the image from Pycon Fr 2023, since I am making this mock site thank to it!
I found how to do it in this stack overflow post
Just add, to conf.py file:
html_favicon = 'favicon.ico'