Back to Hugo

Permalink

docs/content/en/methods/resource/Permalink.md

0.161.1351 B
Original Source

{{% include "/_common/methods/resource/global-page-remote-resources.md" %}}

The Permalink method on a Resource object writes the resource to the publish directory, typically public, and returns its permalink.

go-html-template
{{ with resources.Get "images/a.jpg" }}
  {{ .Permalink }} → https://example.org/images/a.jpg
{{ end }}