mkdocs-simple-blog
mkdocs-simple-blog copied to clipboard
FEATURE - Persist theme option in localstorage or cookie
I think it would be a cool feature to persist the theme selection in local browser data, to pass this information to all pages, not just the current selection, as a default feature of mkdocks-simple-blog.
Where do you think is the most appropriate place to persist this information? LocalStorage or some cookie usage?
Interesting question @brunoruas2. So, analyzing it, I believe that localstorage should be the way to go, because it is the best way to persist this type of configuration compared to cookies.
For mkdocs-simple-blog there is already an option to configure the theme that will be rendered. This configuration is in the mkdocs.yml file, and you can change the theme type or colors separately.
Example:
theme:
name: simple-blog
favicon: assets/favicon.ico
logo: assets/logo.png
theme_style: light
site_name_style: normal
title_style: bold
colors:
text: black
title: black
primary: black
background: white
components:
site_name: true
title: true
menu: true
preview: true
footer: true
Links: