diff options
author | johannst <johannes.stoelp@gmail.com> | 2021-05-12 01:06:12 +0200 |
---|---|---|
committer | johannst <johannes.stoelp@gmail.com> | 2021-05-12 01:06:12 +0200 |
commit | 475bb60b51b362ba281fb84ff34375070b260cbb (patch) | |
tree | 88f0e0cb164f9e5b2ba713e0133f5ebb033357ab | |
parent | 8e6654ddc8a5801ac5c73488e45635e15b575774 (diff) | |
download | blog-475bb60b51b362ba281fb84ff34375070b260cbb.tar.gz blog-475bb60b51b362ba281fb84ff34375070b260cbb.zip |
added link to tags
-rw-r--r-- | config.toml | 1 | ||||
-rw-r--r-- | templates/index.html | 5 |
2 files changed, 5 insertions, 1 deletions
diff --git a/config.toml b/config.toml index 94e4e3f..41cfe95 100644 --- a/config.toml +++ b/config.toml @@ -17,6 +17,7 @@ highlight_code = true [extra] hyde_links = [ + { url = "$BASE_URL/tags", name = "Tags" }, { url = "https://github.com/johannst", name = "GitHub" }, { url = "https://twitter.com/xjohannst", name = "Twitter" }, ] diff --git a/templates/index.html b/templates/index.html index ad0d413..f0a781e 100644 --- a/templates/index.html +++ b/templates/index.html @@ -42,7 +42,10 @@ <ul class="sidebar-nav"> {% block sidebar_nav %} {% for link in config.extra.hyde_links %} - <li class="sidebar-nav-item"><a href="{{link.url}}">{{link.name}}</a></li> + <!-- johannst START | add replace $BASE_URL --> + {% set link_url = link.url | replace(from="$BASE_URL", to=config.base_url) %} + <li class="sidebar-nav-item"><a href="{{link_url}}">{{link.name}}</a></li> + <!-- johannst END --> {% endfor %} {% endblock sidebar_nav %} </ul> |