Relative access between translations using mkdocs-material theme.
Edit the builtin mkdocs-material site selector to make the links between languages relative.
- If you have in Github Pages the URL
https://foo.github.io/bar/es/config/, you can access it from the URL
https://foo.github.io/bar/config/selecting Spanish in the language selector.
- The current language being displayed will be removed from the language selector, so you will only capable to access to other languages than the current.
pip install mkdocs-material-relative-language-selector
theme: name: material language: en plugins: - search - material-relative-language-selector - mdpo extra: alternate: - name: English lang: en - name: Español link: es lang: es
- If you want to publish your site in Github Pages, you don't need to define any setting because is the default configuration.
- If you want to serve your site
under a custom root domain, define
root_domain: trueto get correct links between languages.
Projects using it
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Hashes for mkdocs_material_relative_language_selector-1.1.4.tar.gz
Hashes for mkdocs_material_relative_language_selector-1.1.4-py3-none-any.whl