mirror of
https://github.com/hugo-fixit/FixIt.git
synced 2026-08-24 15:28:57 +00:00
19 lines
636 B
HTML
19 lines
636 B
HTML
{{- /*
|
|
Render template call stack for debugging purpose.
|
|
Call the partial from any template: {{- partial "_debug/template-call-stack.html" . -}}
|
|
*/ -}}
|
|
{{- $debug := (site.Store.Get "devOpts").debug -}}
|
|
|
|
{{- if $debug | and hugo.IsServer -}}
|
|
{{- with templates.Current -}}
|
|
<ul class="template-call-stack">
|
|
{{- range .Ancestors -}}
|
|
<li><a href="vscode://file/{{ .Filename }}"><small>{{ .Filename }}</small></a></li>
|
|
{{- with .Base -}}
|
|
<li><a href="vscode://file/{{ .Filename }}"><small>{{ .Filename }}</small></a></li>
|
|
{{- end -}}
|
|
{{- end -}}
|
|
</ul>
|
|
{{- end -}}
|
|
{{- end -}}
|