fix(path): broken tag/category link when containing a dot (#368)
This commit is contained in:
@@ -31,7 +31,7 @@
|
||||
|
||||
{{- $categories := slice -}}
|
||||
{{- range .Params.categories -}}
|
||||
{{- $category := . | anchorize | printf "/categories/%v" | $.Site.GetPage -}}
|
||||
{{- $category := partialCached "function/path.html" . . | printf "/categories/%v" | $.Site.GetPage -}}
|
||||
{{- $categories = $categories | append (printf `<a href="%v"><i class="far fa-folder fa-fw"></i>%v</a>` $category.RelPermalink $category.Title) -}}
|
||||
{{- end -}}
|
||||
{{- with delimit $categories " " -}}
|
||||
@@ -58,10 +58,10 @@
|
||||
<i class="fas fa-tags fa-fw"></i>
|
||||
{{- range $index, $value := . -}}
|
||||
{{- if gt $index 0 }}, {{ end -}}
|
||||
{{- $tag := $value | anchorize | printf "/tags/%v" | $.Site.GetPage -}}
|
||||
{{- $tag := partialCached "function/path.html" $value $value | printf "/tags/%v" | $.Site.GetPage -}}
|
||||
<a href="{{ $tag.RelPermalink }}">{{ $tag.Title }}</a>
|
||||
{{- end -}}
|
||||
</div>
|
||||
{{- end -}}
|
||||
</div>
|
||||
</article>
|
||||
</article>
|
||||
Reference in New Issue
Block a user