Document hugo.IsMultihost

This commit is contained in:
Joe Mooring 2024-03-07 05:45:17 -08:00 committed by GitHub
parent c8ef1da978
commit ff0bedd973
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -0,0 +1,33 @@
---
title: hugo.IsMultihost
description: Reports whether each configured language has a unique base URL.
categories: []
keywords: []
action:
aliases: []
related: []
returnType: bool
signatures: [hugo.IsMultihost]
---
{{< new-in v0.123.8 >}}
The `hugo.IsMultihost` function reports whether each configured language has a unique `baseURL`.
{{< code-toggle file=hugo >}}
[languages]
[languages.en]
baseURL = 'https://en.example.org/'
languageName = 'English'
title = 'In English'
weight = 2
[languages.fr]
baseURL = 'https://fr.example.fr'
languageName = 'Français'
title = 'En Français'
weight = 1
{{< /code-toggle >}}
```go-html-template
{{ hugo.IsMultihost }} → true
```