vanilla-hugo/layouts/shortcodes/draftlink.html

7 lines
192 B
HTML
Raw Normal View History

{{- $page := site.GetPage (.Get 1) -}}
{{- if $page -}}
<a href="{{ $page.RelPermalink }}">{{ .Get 0 }}</a>
{{- else -}}
<span class="draft-link">{{ .Get 0 }} (coming soon)</span>
{{- end -}}