<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Partial functions on Hugo</title><link>https://v0-122-0--gohugoio.netlify.app/functions/partials/</link><description>Recent content in Partial functions on Hugo</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://v0-122-0--gohugoio.netlify.app/functions/partials/index.xml" rel="self" type="application/rss+xml"/><item><title>partials.Include</title><link>https://v0-122-0--gohugoio.netlify.app/functions/partials/include/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://v0-122-0--gohugoio.netlify.app/functions/partials/include/</guid><description>Without a return statement, the partial function returns a string of type template.HTML. With a return statement, the partial function can return any data type.
In this example we have three partial templates:
layouts/ └── partials/ ├── average.html ├── breadcrumbs.html └── footer.html The &amp;ldquo;average&amp;rdquo; partial returns the average of one or more numbers. We pass the numbers in context:
{{ $numbers := slice 1 6 7 42 }} {{ $average := partial &amp;#34;average.</description></item><item><title>partials.IncludeCached</title><link>https://v0-122-0--gohugoio.netlify.app/functions/partials/includecached/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://v0-122-0--gohugoio.netlify.app/functions/partials/includecached/</guid><description>Without a return statement, the partialCached function returns a string of type template.HTML. With a return statement, the partialCached function can return any data type.
The partialCached function can offer significant performance gains for complex templates that don&amp;rsquo;t need to be re-rendered on every invocation.
Each Site (or language) has its own partialCached cache, so each site will execute a partial once.
Hugo renders pages in parallel, and will render the partial more than once with concurrent calls to the partialCached function.</description></item></channel></rss>