aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--.cspell.json30
-rw-r--r--.github/stale.yml2
-rw-r--r--.github/workflows/codeql-analysis.yml26
-rw-r--r--.github/workflows/spellcheck.yml5
-rw-r--r--.github/workflows/super-linter.yml41
-rw-r--r--.markdownlint.yaml24
-rw-r--r--.markdownlintignore6
-rw-r--r--.textlintignore3
-rw-r--r--.vscode/extensions.json3
-rw-r--r--README.md6
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/assets/css/_font-family.css2
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/assets/css/_hljs.css11
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/assets/index.js21
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/assets/js/hljs.js19
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/assets/output/css/app.css11
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/assets/output/js/app.js8
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/data/sponsors.toml30
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/layouts/partials/home-page-sections/sponsors.html65
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/package.json18
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/brave-logo.svg1
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/butter-dark.svg1
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/butter-light.svg1
-rw-r--r--_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/forestry-logotype.svg1
-rw-r--r--_vendor/modules.txt2
-rw-r--r--config.toml80
-rw-r--r--config/_default/config.toml38
-rw-r--r--config/_default/menus/menus.en.toml136
-rw-r--r--config/production/config.toml2
-rw-r--r--content/en/about/benefits.md1
-rw-r--r--content/en/about/features.md5
-rw-r--r--content/en/about/hugo-and-gdpr.md6
-rw-r--r--content/en/about/security-model/index.md8
-rw-r--r--content/en/about/what-is-hugo.md2
-rw-r--r--content/en/commands/hugo_completion_bash.md2
-rw-r--r--content/en/commands/hugo_completion_zsh.md6
-rw-r--r--content/en/commands/hugo_new.md1
-rw-r--r--content/en/content-management/_index.md14
-rw-r--r--content/en/content-management/archetypes.md18
-rw-r--r--content/en/content-management/build-options.md23
-rw-r--r--content/en/content-management/comments.md18
-rw-r--r--content/en/content-management/cross-references.md67
-rw-r--r--content/en/content-management/diagrams.md38
-rw-r--r--content/en/content-management/formats.md27
-rw-r--r--content/en/content-management/front-matter.md35
-rw-r--r--content/en/content-management/image-processing/index.md79
-rw-r--r--content/en/content-management/menus.md16
-rw-r--r--content/en/content-management/multilingual.md22
-rw-r--r--content/en/content-management/organization/index.md29
-rw-r--r--content/en/content-management/page-bundles.md44
-rw-r--r--content/en/content-management/page-resources.md29
-rw-r--r--content/en/content-management/related.md29
-rw-r--r--content/en/content-management/sections.md17
-rw-r--r--content/en/content-management/shortcodes.md72
-rw-r--r--content/en/content-management/static-files.md13
-rw-r--r--content/en/content-management/summaries.md18
-rw-r--r--content/en/content-management/syntax-highlighting.md35
-rw-r--r--content/en/content-management/taxonomies.md27
-rw-r--r--content/en/content-management/toc.md18
-rw-r--r--content/en/content-management/types.md19
-rw-r--r--content/en/content-management/urls.md42
-rw-r--r--content/en/contribute/development.md96
-rw-r--r--content/en/contribute/documentation.md31
-rw-r--r--content/en/contribute/themes.md2
-rw-r--r--content/en/functions/GetPage.md2
-rw-r--r--content/en/functions/RenderString.md5
-rw-r--r--content/en/functions/abslangurl.md64
-rw-r--r--content/en/functions/absurl.md75
-rw-r--r--content/en/functions/complement.md77
-rw-r--r--content/en/functions/dateformat.md6
-rw-r--r--content/en/functions/dict.md12
-rw-r--r--content/en/functions/errorf.md2
-rw-r--r--content/en/functions/findRe.md46
-rw-r--r--content/en/functions/format.md2
-rw-r--r--content/en/functions/get.md5
-rw-r--r--content/en/functions/getenv.md3
-rw-r--r--content/en/functions/haschildren.md22
-rw-r--r--content/en/functions/hasmenucurrent.md2
-rw-r--r--content/en/functions/highlight.md4
-rw-r--r--content/en/functions/hugo.md6
-rw-r--r--content/en/functions/images/index.md4
-rw-r--r--content/en/functions/int.md2
-rw-r--r--content/en/functions/intersect.md2
-rw-r--r--content/en/functions/jsonify.md11
-rw-r--r--content/en/functions/markdownify.md5
-rw-r--r--content/en/functions/md5.md2
-rw-r--r--content/en/functions/partialCached.md2
-rw-r--r--content/en/functions/ref.md2
-rw-r--r--content/en/functions/relLangURL.md65
-rw-r--r--content/en/functions/relref.md2
-rw-r--r--content/en/functions/relurl.md74
-rw-r--r--content/en/functions/replacere.md51
-rw-r--r--content/en/functions/safeHTML.md2
-rw-r--r--content/en/functions/safeHTMLAttr.md42
-rw-r--r--content/en/functions/scratch.md6
-rw-r--r--content/en/functions/split.md17
-rw-r--r--content/en/functions/strings.Count.md2
-rw-r--r--content/en/functions/strings.HasSuffix.md2
-rw-r--r--content/en/functions/symdiff.md5
-rw-r--r--content/en/functions/upper.md2
-rw-r--r--content/en/functions/urlize.md2
-rw-r--r--content/en/functions/urlquery.md33
-rw-r--r--content/en/functions/urls.Parse.md4
-rw-r--r--content/en/functions/where.md4
-rw-r--r--content/en/getting-started/_index.md4
-rw-r--r--content/en/getting-started/configuration-markup.md13
-rw-r--r--content/en/getting-started/configuration.md104
-rw-r--r--content/en/getting-started/directory-structure.md13
-rw-r--r--content/en/getting-started/external-learning-resources/index.md6
-rw-r--r--content/en/getting-started/installing.md586
-rw-r--r--content/en/getting-started/quick-start.md22
-rw-r--r--content/en/getting-started/usage.md272
-rw-r--r--content/en/hosting-and-deployment/deployment-with-rclone.md4
-rw-r--r--content/en/hosting-and-deployment/deployment-with-rsync.md26
-rw-r--r--content/en/hosting-and-deployment/hosting-on-21yunbox.md2
-rw-r--r--content/en/hosting-and-deployment/hosting-on-aws-amplify.md7
-rw-r--r--content/en/hosting-and-deployment/hosting-on-azure-static-web-apps.md2
-rw-r--r--content/en/hosting-and-deployment/hosting-on-azure.md101
-rw-r--r--content/en/hosting-and-deployment/hosting-on-firebase.md54
-rw-r--r--content/en/hosting-and-deployment/hosting-on-github.md6
-rw-r--r--content/en/hosting-and-deployment/hosting-on-gitlab.md6
-rw-r--r--content/en/hosting-and-deployment/hosting-on-keycdn.md11
-rw-r--r--content/en/hosting-and-deployment/hosting-on-netlify.md23
-rw-r--r--content/en/hosting-and-deployment/hosting-on-render.md6
-rw-r--r--content/en/hugo-modules/_index.md2
-rw-r--r--content/en/hugo-modules/configuration.md23
-rw-r--r--content/en/hugo-modules/theme-components.md9
-rw-r--r--content/en/hugo-modules/use-modules.md16
-rwxr-xr-xcontent/en/hugo-pipes/_index.md2
-rwxr-xr-xcontent/en/hugo-pipes/babel.md31
-rwxr-xr-xcontent/en/hugo-pipes/bundling.md1
-rwxr-xr-xcontent/en/hugo-pipes/fingerprint.md5
-rwxr-xr-xcontent/en/hugo-pipes/introduction.md10
-rw-r--r--content/en/hugo-pipes/js.md44
-rwxr-xr-xcontent/en/hugo-pipes/minification.md4
-rwxr-xr-xcontent/en/hugo-pipes/postcss.md11
-rwxr-xr-xcontent/en/hugo-pipes/postprocess.md2
-rwxr-xr-xcontent/en/hugo-pipes/resource-from-string.md6
-rwxr-xr-xcontent/en/hugo-pipes/resource-from-template.md7
-rwxr-xr-xcontent/en/hugo-pipes/scss-sass.md17
-rw-r--r--content/en/installation/_index.md15
-rw-r--r--content/en/installation/bsd.md79
-rw-r--r--content/en/installation/common/01-editions.md8
-rw-r--r--content/en/installation/common/02-prerequisites.md27
-rw-r--r--content/en/installation/common/03-prebuilt-binaries.md21
-rw-r--r--content/en/installation/common/04-docker.md10
-rw-r--r--content/en/installation/common/05-build-from-source.md20
-rw-r--r--content/en/installation/common/homebrew.md9
-rw-r--r--content/en/installation/common/index.md3
-rw-r--r--content/en/installation/linux.md125
-rw-r--r--content/en/installation/macos.md48
-rw-r--r--content/en/installation/windows.md63
-rw-r--r--content/en/news/0.28-relnotes/index.md2
-rw-r--r--content/en/news/0.89.4-relnotes/index.md7
-rw-r--r--content/en/readfiles/dateformatting.md12
-rw-r--r--content/en/readfiles/pages-vs-site-pages.md2
-rw-r--r--content/en/showcase/alora-labs/bio.md3
-rw-r--r--content/en/showcase/alora-labs/featured.pngbin0 -> 83801 bytes
-rw-r--r--content/en/showcase/alora-labs/index.md18
-rw-r--r--content/en/showcase/ampio-help/bio.md11
-rw-r--r--content/en/showcase/ampio-help/featured.pngbin0 -> 1495152 bytes
-rw-r--r--content/en/showcase/ampio-help/index.md77
-rw-r--r--content/en/showcase/digitalgov/index.md2
-rw-r--r--content/en/showcase/fireship/index.md2
-rw-r--r--content/en/showcase/forestry/bio.md3
-rw-r--r--content/en/showcase/godot-tutorials/bio.md4
-rw-r--r--content/en/showcase/godot-tutorials/index.md4
-rw-r--r--content/en/showcase/hapticmedia/index.md7
-rw-r--r--content/en/showcase/hartwell-insurance/index.md2
-rw-r--r--content/en/showcase/small-multiples/bio.md3
-rw-r--r--content/en/showcase/small-multiples/featured-small-multiples.pngbin374273 -> 0 bytes
-rw-r--r--content/en/showcase/small-multiples/index.md47
-rw-r--r--content/en/showcase/template/index.md12
-rw-r--r--content/en/templates/404.md5
-rw-r--r--content/en/templates/alternatives.md21
-rw-r--r--content/en/templates/base.md5
-rw-r--r--content/en/templates/data-templates.md42
-rw-r--r--content/en/templates/files.md8
-rw-r--r--content/en/templates/internal.md56
-rw-r--r--content/en/templates/introduction.md45
-rw-r--r--content/en/templates/lists.md12
-rw-r--r--content/en/templates/lookup-order.md2
-rw-r--r--content/en/templates/menu-templates.md17
-rw-r--r--content/en/templates/ordering-and-grouping.md344
-rw-r--r--content/en/templates/output-formats.md51
-rw-r--r--content/en/templates/pagination.md13
-rw-r--r--content/en/templates/partials.md4
-rw-r--r--content/en/templates/render-hooks.md30
-rw-r--r--content/en/templates/rss.md2
-rw-r--r--content/en/templates/section-templates.md11
-rw-r--r--content/en/templates/shortcode-templates.md56
-rw-r--r--content/en/templates/taxonomy-templates.md2
-rw-r--r--content/en/templates/template-debugging.md21
-rw-r--r--content/en/templates/views.md6
-rw-r--r--content/en/tools/_index.md1
-rw-r--r--content/en/tools/editors.md6
-rw-r--r--content/en/tools/frontends.md18
-rw-r--r--content/en/tools/migrations.md10
-rw-r--r--content/en/tools/other.md19
-rw-r--r--content/en/tools/search.md8
-rw-r--r--content/en/troubleshooting/build-performance.md24
-rw-r--r--content/en/troubleshooting/faq.md21
-rw-r--r--content/en/variables/files.md2
-rw-r--r--content/en/variables/git.md2
-rw-r--r--content/en/variables/menus.md9
-rw-r--r--content/en/variables/page.md21
-rw-r--r--content/en/variables/pages.md4
-rw-r--r--content/en/variables/shortcodes.md5
-rw-r--r--content/en/variables/site.md11
-rw-r--r--content/en/variables/sitemap.md3
-rw-r--r--content/zh/content-management/_index.md5
-rw-r--r--data/articles.toml8
-rw-r--r--data/docs.json25
-rw-r--r--go.mod2
-rw-r--r--go.sum4
-rw-r--r--layouts/partials/boxes-section-summaries.html39
-rw-r--r--netlify.toml8
-rw-r--r--resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_1024x512_fill_catmullrom_top_2.pngbin0 -> 68339 bytes
-rw-r--r--resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_640x0_resize_catmullrom_2.pngbin0 -> 23262 bytes
-rw-r--r--resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_8298a1fa052279512823ecd663d6f9c8.pngbin0 -> 25555 bytes
-rw-r--r--static/images/hosting-and-deployment/hosting-on-azure/basic-app-details.pngbin0 -> 54346 bytes
-rw-r--r--static/images/hosting-and-deployment/hosting-on-azure/create-in-portal.pngbin0 -> 63683 bytes
221 files changed, 2478 insertions, 2812 deletions
diff --git a/.cspell.json b/.cspell.json
index 1a197ea7b..0958b7645 100644
--- a/.cspell.json
+++ b/.cspell.json
@@ -34,6 +34,7 @@
"brlink",
"Brotli",
"Browsersync",
+ "canonicalization",
"canonify",
"Catmull",
"Catwoman",
@@ -61,6 +62,8 @@
"datatable",
"DATOCMS",
"debugconfig",
+ "defang",
+ "Deindent",
"DELIM",
"dhersam",
"digitalcraftsman",
@@ -72,17 +75,21 @@
"DRING",
"Eiqc",
"Eliott",
+ "embeddable",
"Emojify",
"Enwrite",
"eopkg",
"eparis",
"errorf",
"erroridf",
+ "esbuild",
"Evernote",
+ "Exif",
"exitwp",
"expirydate",
"Feminella",
"firstpost",
+ "Flickr",
"Formspree",
"fpath",
"Francia",
@@ -91,10 +98,12 @@
"funcs",
"funcsig",
"Garen",
+ "Garuda",
"gcloud",
"Getenv",
"getjson",
"getpage",
+ "Gitee",
"Gmfc",
"Goel",
"Gohugo",
@@ -106,6 +115,7 @@
"govendor",
"Gowans",
"Grayscale",
+ "Gregor",
"Gruber",
"gtag",
"gvfs",
@@ -141,10 +151,12 @@
"Joomla",
"JRBR",
"jsonify",
+ "Karmada",
"katex",
"keycdn",
"KEYVALS",
"kubernetes",
+ "Kubuntu",
"Lanczos",
"langformatnumber",
"lastmod",
@@ -152,6 +164,7 @@
"linktitle",
"Lipi",
"lrwxr",
+ "Lubuntu",
"maingo",
"markdownified",
"markdownify",
@@ -188,6 +201,7 @@
"newparam",
"Nichlas",
"Nikhil",
+ "Nikola",
"Njjy",
"nlist",
"nobr",
@@ -221,6 +235,7 @@
"Poupin",
"prerender",
"println",
+ "Pritchard",
"publishdate",
"Pygments",
"qref",
@@ -249,6 +264,7 @@
"safejs",
"Samsa",
"schemaorg",
+ "setx",
"Shekhar",
"Shortcode",
"Shortcodes",
@@ -257,7 +273,9 @@
"Sindre",
"sitemapindex",
"sitemapxml",
+ "slugorfilename",
"Smartcrop",
+ "Sobre",
"Sprintf",
"Startseite",
"strconv",
@@ -278,6 +296,7 @@
"Tknx",
"TLDR",
"TMPDIR",
+ "toclevels",
"TOCSS",
"todos",
"tojson",
@@ -288,6 +307,8 @@
"toyaml",
"twitteruser",
"Unmarshal",
+ "unpublishdate",
+ "Unsharp",
"urlize",
"urlset",
"utimestamp",
@@ -301,15 +322,19 @@
"wibble",
"wordcount",
"workson",
+ "Wowchemy",
"wpxr",
"Xbaabbab",
+ "Xubuntu",
"xvzf",
"yoyoyo",
+ "yunbox",
"Zgotmpl",
+ "Zorin",
"zzbbaabb",
"مدونتي"
],
- "language": "en,en-GB,en-US,de,fr",
+ "language": "en,en-US,de,fr",
"allowCompoundWords": true,
"files": [
"**/*.md"
@@ -331,5 +356,6 @@
"**/news/*",
"**/showcase/*"
],
- "useGitignore": true
+ "useGitignore": true,
+ "enabled": true
}
diff --git a/.github/stale.yml b/.github/stale.yml
index 389205294..1e72eb329 100644
--- a/.github/stale.yml
+++ b/.github/stale.yml
@@ -17,6 +17,6 @@ markComment: >
If you still think this is important, please tell us why.
This issue will automatically be closed in the near future if no further activity occurs. Thank you for all your contributions.
-
+
# Comment to post when closing a stale issue. Set to `false` to disable
closeComment: false
diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml
new file mode 100644
index 000000000..30f98a000
--- /dev/null
+++ b/.github/workflows/codeql-analysis.yml
@@ -0,0 +1,26 @@
+name: "CodeQL"
+
+on:
+ schedule:
+ - cron: "0 0 1 * *"
+
+jobs:
+ analyze:
+ name: Analyze
+ runs-on: ubuntu-latest
+ permissions:
+ actions: read
+ contents: read
+ security-events: write
+
+ steps:
+ - name: Checkout repository
+ uses: actions/checkout@v3
+
+ - name: Initialize CodeQL
+ uses: github/codeql-action/init@v2
+ with:
+ languages: "javascript"
+
+ - name: Perform CodeQL Analysis
+ uses: github/codeql-action/analyze@v2
diff --git a/.github/workflows/spellcheck.yml b/.github/workflows/spellcheck.yml
index 6f68fee18..594621604 100644
--- a/.github/workflows/spellcheck.yml
+++ b/.github/workflows/spellcheck.yml
@@ -1,4 +1,4 @@
-name: 'Check spelling'
+name: "Check spelling"
on: # rebuild any PRs and main branch changes
push:
branches-ignore:
@@ -15,6 +15,7 @@ jobs:
- uses: actions/checkout@v3
- uses: streetsidesoftware/cspell-action@v2
with:
+ check_dot_files: false
+ incremental_files_only: true
inline: warning
strict: false
- incremental_files_only: true
diff --git a/.github/workflows/super-linter.yml b/.github/workflows/super-linter.yml
new file mode 100644
index 000000000..efd206960
--- /dev/null
+++ b/.github/workflows/super-linter.yml
@@ -0,0 +1,41 @@
+name: Super Linter
+
+on:
+ workflow_dispatch:
+
+permissions:
+ contents: read # to fetch code (actions/checkout)
+
+jobs:
+ build:
+ permissions:
+ contents: read # to fetch code (actions/checkout)
+ statuses: write # to mark status of each linter run (github/super-linter/slim)
+
+ name: Lint Code Base
+ runs-on: ubuntu-latest
+ if: ${{ github.actor != 'dependabot[bot]' }}
+
+ steps:
+ - name: Checkout Code
+ uses: actions/checkout@v3
+
+ - name: Lint Code Base
+ uses: github/super-linter/slim@v4
+ env:
+ DEFAULT_BRANCH: master
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ IGNORE_GITIGNORED_FILES: true
+ LINTER_RULES_PATH: /
+ LOG_LEVEL: NOTICE
+ MARKDOWN_CONFIG_FILE: .markdownlint.yaml
+ SUPPRESS_POSSUM: true
+ VALIDATE_CSS: false
+ VALIDATE_EDITORCONFIG: false
+ VALIDATE_GITLEAKS: false
+ VALIDATE_HTML: false
+ VALIDATE_JAVASCRIPT_STANDARD: false
+ VALIDATE_JSCPD: false
+ VALIDATE_NATURAL_LANGUAGE: false
+ VALIDATE_SHELL_SHFMT: false
+ VALIDATE_XML: false
diff --git a/.markdownlint.yaml b/.markdownlint.yaml
index 1b76d280e..58f84dc67 100644
--- a/.markdownlint.yaml
+++ b/.markdownlint.yaml
@@ -1,4 +1,24 @@
# https://github.com/DavidAnson/markdownlint/blob/main/doc/Rules.md
-MD013: false # Line length
-MD033: false # Inline HTML
+MD002: false
+MD003: false
+MD004: false
+MD007: false
+MD012:
+ maximum: 2
+MD013: false
+MD014: false
+MD022: false
+MD024: false
+MD031: false
+MD032: false
+MD033: false
+MD034: false
+MD036: false
+MD037: false
+MD038: false
+MD041: false
+MD046: false
+MD049: false
+MD050: false
+MD053: false
diff --git a/.markdownlintignore b/.markdownlintignore
new file mode 100644
index 000000000..4ac45b395
--- /dev/null
+++ b/.markdownlintignore
@@ -0,0 +1,6 @@
+**/commands/**
+**/functions/**
+**/news/**
+**/showcase/**
+**/zh/**
+**/license.md
diff --git a/.textlintignore b/.textlintignore
new file mode 100644
index 000000000..97a18e37c
--- /dev/null
+++ b/.textlintignore
@@ -0,0 +1,3 @@
+**/news/**
+**/showcase/**
+**/zh/** \ No newline at end of file
diff --git a/.vscode/extensions.json b/.vscode/extensions.json
index 4ca64b165..76c6afe3f 100644
--- a/.vscode/extensions.json
+++ b/.vscode/extensions.json
@@ -1,6 +1,7 @@
{
"recommendations": [
+ "DavidAnson.vscode-markdownlint",
"EditorConfig.EditorConfig",
- "esbenp.prettier-vscode",
+ "streetsidesoftware.code-spell-checker"
]
}
diff --git a/README.md b/README.md
index a2c767b7b..072714a02 100644
--- a/README.md
+++ b/README.md
@@ -7,11 +7,11 @@ Documentation site for [Hugo](https://github.com/gohugoio/hugo), the very fast a
## Contributing
-We welcome contributions to Hugo of any kind including documentation, suggestions, bug reports, pull requests etc. Also check out our [contribution guide](https://gohugo.io/contribute/documentation/). We would love to hear from you.
+We welcome contributions to Hugo of any kind including documentation, suggestions, bug reports, pull requests etc. Also check out our [contribution guide](https://gohugo.io/contribute/documentation/). We would love to hear from you.
-Note that this repository contains solely the documentation for Hugo. For contributions that aren't documentation-related please refer to the [hugo](https://github.com/gohugoio/hugo) repository.
+Note that this repository contains solely the documentation for Hugo. For contributions that aren't documentation-related please refer to the [hugo](https://github.com/gohugoio/hugo) repository.
-*Pull requests shall **only** contain changes to the actual documentation. However, changes on the code base of Hugo **and** the documentation shall be a single, atomic pull request in the [hugo](https://github.com/gohugoio/hugo) repository.*
+*Pull requests shall **only** contain changes to the actual documentation. However, changes on the codebase of Hugo **and** the documentation shall be a single, atomic pull request in the [hugo](https://github.com/gohugoio/hugo) repository.*
Spelling fixes are most welcomed, and if you want to contribute longer sections to the documentation, it would be great if you had the following criteria in mind when writing:
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/assets/css/_font-family.css b/_vendor/github.com/gohugoio/gohugoioTheme/assets/css/_font-family.css
index 9b451cf1c..440b5efdd 100644
--- a/_vendor/github.com/gohugoio/gohugoioTheme/assets/css/_font-family.css
+++ b/_vendor/github.com/gohugoio/gohugoioTheme/assets/css/_font-family.css
@@ -1,4 +1,4 @@
-/* From http://cssfontstack.com */
+/* From https://www.cssfontstack.com */
code, .code, pre code, .highlight pre {
font-family: 'inconsolata',Menlo,Monaco,'Courier New',monospace;
}
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/assets/css/_hljs.css b/_vendor/github.com/gohugoio/gohugoioTheme/assets/css/_hljs.css
deleted file mode 100644
index c49107655..000000000
--- a/_vendor/github.com/gohugoio/gohugoioTheme/assets/css/_hljs.css
+++ /dev/null
@@ -1,11 +0,0 @@
-/* modified from:*/
-@import 'highlight.js/styles/atom-one-light.css';
-
-/* hljs-template-variable covers the handlebars templating*/
-.hljs-template-variable {
- color: var(--primary-color);
-}
-
-.hljs-attr {
- color: var(--accent-color-light);
-}
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/assets/index.js b/_vendor/github.com/gohugoio/gohugoioTheme/assets/index.js
index e309bdb99..11b320d74 100644
--- a/_vendor/github.com/gohugoio/gohugoioTheme/assets/index.js
+++ b/_vendor/github.com/gohugoio/gohugoioTheme/assets/index.js
@@ -1,12 +1,11 @@
-require("typeface-muli")
+require('typeface-muli');
import styles from './css/main.css';
-import './js/clipboardjs.js'
-import './js/codeblocks.js'
-import './js/docsearch.js'
-import './js/hljs.js'
-import './js/lazysizes.js'
-import './js/menutoggle.js'
-import './js/scrolldir.js'
-import './js/smoothscroll.js'
-import './js/tabs.js'
-import './js/nojs.js'
+import './js/clipboardjs.js';
+import './js/codeblocks.js';
+import './js/docsearch.js';
+import './js/lazysizes.js';
+import './js/menutoggle.js';
+import './js/scrolldir.js';
+import './js/smoothscroll.js';
+import './js/tabs.js';
+import './js/nojs.js';
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/assets/js/hljs.js b/_vendor/github.com/gohugoio/gohugoioTheme/assets/js/hljs.js
deleted file mode 100644
index c2252e783..000000000
--- a/_vendor/github.com/gohugoio/gohugoioTheme/assets/js/hljs.js
+++ /dev/null
@@ -1,19 +0,0 @@
-var hljs = require('highlight.js/lib/highlight.js');
-
-hljs.registerLanguage('bash', require('highlight.js/lib/languages/bash'));
-hljs.registerLanguage('css', require('highlight.js/lib/languages/css'));
-hljs.registerLanguage('markdown', require('highlight.js/lib/languages/markdown'));
-hljs.registerLanguage('diff', require('highlight.js/lib/languages/diff'));
-// hljs.registerLanguage('go', require('highlight.js/lib/languages/go'));
-hljs.registerLanguage('javascript', require('highlight.js/lib/languages/javascript'));
-hljs.registerLanguage('json', require('highlight.js/lib/languages/json'));
-hljs.registerLanguage('yaml', require('highlight.js/lib/languages/yaml'));
-hljs.registerLanguage('xml', require('highlight.js/lib/languages/xml'));
-hljs.registerLanguage('html', require('highlight.js/lib/languages/handlebars'));
-
-hljs.registerLanguage("go", function(e) {
- var t = { keyword: "code output note warning break default func interface select case map struct chan else goto package switch const fallthrough if range end type continue for import return var go defer bool byte complex64 complex128 float32 float64 int8 int16 int32 int64 string uint8 uint16 uint32 uint64 int uint uintptr rune id autoplay Get", literal: "file download copy true false iota nil Pages with", built_in: "append cap close complex highlight copy imag len make new panic print println real recover delete Site Data tweet youtube ref relref vimeo instagram gist figure innershortcode" };
- return { aliases: ["golang","hugo"], k: t, i: "</", c: [e.CLCM, e.CBCM, { cN: "string", v: [e.QSM, { b: "'", e: "[^\\\\]'" }, { b: "`", e: "`" }] }, { cN: "number", v: [{ b: e.CNR + "[dflsi]", r: 1 }, e.CNM] }, { b: /:=/ }, { cN: "function", bK: "func", e: /\s*\{/, eE: !0, c: [e.TM, { cN: "params", b: /\(/, e: /\)/, k: t, i: /["']/ }] }] }
-});
-
-hljs.initHighlightingOnLoad();
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/assets/output/css/app.css b/_vendor/github.com/gohugoio/gohugoioTheme/assets/output/css/app.css
index b5e5faa84..f5d56e95a 100644
--- a/_vendor/github.com/gohugoio/gohugoioTheme/assets/output/css/app.css
+++ b/_vendor/github.com/gohugoio/gohugoioTheme/assets/output/css/app.css
@@ -4083,7 +4083,7 @@ img { max-width: 100%; }
max-width: 30em;
}
.measure-wide-l {
- max-width: 40em;
+ max-width: 34em;
}
.measure-narrow-l {
max-width: 20em;
@@ -4768,11 +4768,6 @@ h6:hover .header-link {
padding: 0;
margin: 0;
}
-pre, .pre {
- overflow-x: auto;
- overflow-y: hidden;
- overflow: scroll;
-}
code {
padding: 0.2em;
margin: 0;
@@ -4780,7 +4775,7 @@ code {
background-color: rgba(27, 31, 35, .05);
border-radius: 3px;
}
-pre code {
+pre code {
display: block;
padding: 1.5em 1.5em;
font-size: .875rem;
@@ -4992,7 +4987,7 @@ dd {
font-size: calc(0.70833rem + 0.83333vw);
}
}
-/* From http://cssfontstack.com */
+/* From https://www.cssfontstack.com */
code, .code, pre code, .highlight pre {
font-family: 'inconsolata',Menlo,Monaco,'Courier New',monospace;
}
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/assets/output/js/app.js b/_vendor/github.com/gohugoio/gohugoioTheme/assets/output/js/app.js
index 8d871af7b..6ddef7b0f 100644
--- a/_vendor/github.com/gohugoio/gohugoioTheme/assets/output/js/app.js
+++ b/_vendor/github.com/gohugoio/gohugoioTheme/assets/output/js/app.js
@@ -1,17 +1,17 @@
-!function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=1)}([function(e,t,n){!function(t,n){var r=function(e,t){"use strict";if(!t.getElementsByClassName)return;var n,r,i=t.documentElement,s=e.Date,o=e.HTMLPictureElement,a=e.addEventListener,c=e.setTimeout,u=e.requestAnimationFrame||c,l=e.requestIdleCallback,h=/^picture$/i,d=["load","error","lazyincluded","_lazyloaded"],f={},p=Array.prototype.forEach,g=function(e,t){return f[t]||(f[t]=new RegExp("(\\s|^)"+t+"(\\s|$)")),f[t].test(e.getAttribute("class")||"")&&f[t]},m=function(e,t){g(e,t)||e.setAttribute("class",(e.getAttribute("class")||"").trim()+" "+t)},v=function(e,t){var n;(n=g(e,t))&&e.setAttribute("class",(e.getAttribute("class")||"").replace(n," "))},y=function(e,t,n){var r=n?"addEventListener":"removeEventListener";n&&y(e,t),d.forEach((function(n){e[r](n,t)}))},b=function(e,r,i,s,o){var a=t.createEvent("Event");return i||(i={}),i.instance=n,a.initEvent(r,!s,!o),a.detail=i,e.dispatchEvent(a),a},w=function(t,n){var i;!o&&(i=e.picturefill||r.pf)?(n&&n.src&&!t.getAttribute("srcset")&&t.setAttribute("srcset",n.src),i({reevaluate:!0,elements:[t]})):n&&n.src&&(t.src=n.src)},_=function(e,t){return(getComputedStyle(e,null)||{})[t]},E=function(e,t,n){for(n=n||e.offsetWidth;n<r.minSize&&t&&!e._lazysizesWidth;)n=t.offsetWidth,t=t.parentNode;return n},x=(O=[],T=[],k=O,R=function(){var e=k;for(k=O.length?T:O,A=!0,N=!1;e.length;)e.shift()();A=!1},M=function(e,n){A&&!n?e.apply(this,arguments):(k.push(e),N||(N=!0,(t.hidden?c:u)(R)))},M._lsFlush=R,M),S=function(e,t){return t?function(){x(e)}:function(){var t=this,n=arguments;x((function(){e.apply(t,n)}))}},C=function(e){var t,n,r=function(){t=null,e()},i=function(){var e=s.now()-n;e<99?c(i,99-e):(l||r)(r)};return function(){n=s.now(),t||(t=c(i,99))}};var A,N,O,T,k,R,M;!function(){var t,n={lazyClass:"lazyload",loadedClass:"lazyloaded",loadingClass:"lazyloading",preloadClass:"lazypreload",errorClass:"lazyerror",autosizesClass:"lazyautosizes",srcAttr:"data-src",srcsetAttr:"data-srcset",sizesAttr:"data-sizes",minSize:40,customMedia:{},init:!0,expFactor:1.5,hFac:.8,loadMode:2,loadHidden:!0,ricTimeout:0,throttleDelay:125};for(t in r=e.lazySizesConfig||e.lazysizesConfig||{},n)t in r||(r[t]=n[t]);e.lazySizesConfig=r,c((function(){r.init&&D()}))}();var L=(ee=/^img$/i,te=/^iframe$/i,ne="onscroll"in e&&!/(gle|ing)bot/.test(navigator.userAgent),re=0,ie=0,se=-1,oe=function(e){ie--,e&&e.target&&y(e.target,oe),(!e||ie<0||!e.target)&&(ie=0)},ae=function(e,n){var r,s=e,o="hidden"==_(t.body,"visibility")||"hidden"!=_(e.parentNode,"visibility")&&"hidden"!=_(e,"visibility");for(J-=n,Q+=n,W-=n,G+=n;o&&(s=s.offsetParent)&&s!=t.body&&s!=i;)(o=(_(s,"opacity")||1)>0)&&"visible"!=_(s,"overflow")&&(r=s.getBoundingClientRect(),o=G>r.left&&W<r.right&&Q>r.top-1&&J<r.bottom+1);return o},ce=function(){var e,s,o,a,c,u,l,h,d,f=n.elements;if((z=r.loadMode)&&ie<8&&(e=f.length)){s=0,se++,null==Z&&("expand"in r||(r.expand=i.clientHeight>500&&i.clientWidth>500?500:370),X=r.expand,Z=X*r.expFactor),re<Z&&ie<1&&se>2&&z>2&&!t.hidden?(re=Z,se=0):re=z>1&&se>1&&ie<6?X:0;for(;s<e;s++)if(f[s]&&!f[s]._lazyRace)if(ne)if((h=f[s].getAttribute("data-expand"))&&(u=1*h)||(u=re),d!==u&&(K=innerWidth+u*Y,V=innerHeight+u,l=-1*u,d=u),o=f[s].getBoundingClientRect(),(Q=o.bottom)>=l&&(J=o.top)<=V&&(G=o.right)>=l*Y&&(W=o.left)<=K&&(Q||G||W||J)&&(r.loadHidden||"hidden"!=_(f[s],"visibility"))&&(q&&ie<3&&!h&&(z<3||se<4)||ae(f[s],u))){if(ge(f[s]),c=!0,ie>9)break}else!c&&q&&!a&&ie<4&&se<4&&z>2&&(B[0]||r.preloadAfterLoad)&&(B[0]||!h&&(Q||G||W||J||"auto"!=f[s].getAttribute(r.sizesAttr)))&&(a=B[0]||f[s]);else ge(f[s]);a&&!c&&ge(a)}},ue=function(e){var t,n=0,i=r.throttleDelay,o=r.ricTimeout,a=function(){t=!1,n=s.now(),e()},u=l&&o>49?function(){l(a,{timeout:o}),o!==r.ricTimeout&&(o=r.ricTimeout)}:S((function(){c(a)}),!0);return function(e){var r;(e=!0===e)&&(o=33),t||(t=!0,(r=i-(s.now()-n))<0&&(r=0),e||r<9?u():c(u,r))}}(ce),le=function(e){m(e.target,r.loadedClass),v(e.target,r.loadingClass),y(e.target,de),b(e.target,"lazyloaded")},he=S(le),de=function(e){he({target:e.target})},fe=function(e){var t,n=e.getAttribute(r.srcsetAttr);(t=r.customMedia[e.getAttribute("data-media")||e.getAttribute("media")])&&e.setAttribute("media",t),n&&e.setAttribute("srcset",n)},pe=S((function(e,t,n,i,s){var o,a,u,l,d,f;(d=b(e,"lazybeforeunveil",t)).defaultPrevented||(i&&(n?m(e,r.autosizesClass):e.setAttribute("sizes",i)),a=e.getAttribute(r.srcsetAttr),o=e.getAttribute(r.srcAttr),s&&(l=(u=e.parentNode)&&h.test(u.nodeName||"")),f=t.firesLoad||"src"in e&&(a||o||l),d={target:e},f&&(y(e,oe,!0),clearTimeout(F),F=c(oe,2500),m(e,r.loadingClass),y(e,de,!0)),l&&p.call(u.getElementsByTagName("source"),fe),a?e.setAttribute("srcset",a):o&&!l&&(te.test(e.nodeName)?function(e,t){try{e.contentWindow.location.replace(t)}catch(n){e.src=t}}(e,o):e.src=o),s&&(a||l)&&w(e,{src:o})),e._lazyRace&&delete e._lazyRace,v(e,r.lazyClass),x((function(){(!f||e.complete&&e.naturalWidth>1)&&(f?oe(d):ie--,le(d))}),!0)})),ge=function(e){var t,n=ee.test(e.nodeName),i=n&&(e.getAttribute(r.sizesAttr)||e.getAttribute("sizes")),s="auto"==i;(!s&&q||!n||!e.getAttribute("src")&&!e.srcset||e.complete||g(e,r.errorClass)||!g(e,r.lazyClass))&&(t=b(e,"lazyunveilread").detail,s&&I.updateElem(e,!0,e.offsetWidth),e._lazyRace=!0,ie++,pe(e,t,s,i,n))},me=function(){if(!q)if(s.now()-U<999)c(me,999);else{var e=C((function(){r.loadMode=3,ue()}));q=!0,r.loadMode=3,ue(),a("scroll",(function(){3==r.loadMode&&(r.loadMode=2),e()}),!0)}},{_:function(){U=s.now(),n.elements=t.getElementsByClassName(r.lazyClass),B=t.getElementsByClassName(r.lazyClass+" "+r.preloadClass),Y=r.hFac,a("scroll",ue,!0),a("resize",ue,!0),e.MutationObserver?new MutationObserver(ue).observe(i,{childList:!0,subtree:!0,attributes:!0}):(i.addEventListener("DOMNodeInserted",ue,!0),i.addEventListener("DOMAttrModified",ue,!0),setInterval(ue,999)),a("hashchange",ue,!0),["focus","mouseover","click","load","transitionend","animationend","webkitAnimationEnd"].forEach((function(e){t.addEventListener(e,ue,!0)})),/d$|^c/.test(t.readyState)?me():(a("load",me),t.addEventListener("DOMContentLoaded",ue),c(me,2e4)),n.elements.length?(ce(),x._lsFlush()):ue()},checkElems:ue,unveil:ge}),I=(P=S((function(e,t,n,r){var i,s,o;if(e._lazysizesWidth=r,r+="px",e.setAttribute("sizes",r),h.test(t.nodeName||""))for(s=0,o=(i=t.getElementsByTagName("source")).length;s<o;s++)i[s].setAttribute("sizes",r);n.detail.dataAttr||w(e,n.detail)})),$=function(e,t,n){var r,i=e.parentNode;i&&(n=E(e,i,n),(r=b(e,"lazybeforesizes",{width:n,dataAttr:!!t})).defaultPrevented||(n=r.detail.width)&&n!==e._lazysizesWidth&&P(e,i,r,n))},H=C((function(){var e,t=j.length;if(t)for(e=0;e<t;e++)$(j[e])})),{_:function(){j=t.getElementsByClassName(r.autosizesClass),a("resize",H)},checkElems:H,updateElem:$}),D=function(){D.i||(D.i=!0,I._(),L._())};var j,P,$,H;var B,q,F,z,U,K,V,J,W,G,Q,X,Z,Y,ee,te,ne,re,ie,se,oe,ae,ce,ue,le,he,de,fe,pe,ge,me;return n={cfg:r,autoSizer:I,loader:L,init:D,uP:w,aC:m,rC:v,hC:g,fire:b,gW:E,rAF:x}}(t,t.document);t.lazySizes=r,e.exports&&(e.exports=r)}(window)},function(e,t,n){"use strict";n.r(t);n(3),n(4),n(6),n(7),n(9),n(20),n(22),n(23),n(25),n(26),n(27);n(2)},function(e,t,n){},function(e,t,n){},function(e,t,n){function r(e,t){e.setAttribute("class","copied bg-primary-color-dark f6 absolute top-0 right-0 lh-solid hover-bg-primary-color-dark bn white ph3 pv2"),e.setAttribute("aria-label",t)}new(n(5))(".copy",{target:function(e){return e.classList.contains("copy-toggle")?e.previousElementSibling:e.nextElementSibling}}).on("success",(function(e){r(e.trigger,"Copied!"),e.clearSelection()})).on("error",(function(e){r(e.trigger,function(e,t){var n="",r="cut"===t?"X":"C";n=isMac?"Press ⌘-"+r:"Press Ctrl-"+r;return n}(e.action))}))},function(e,t,n){
+!function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=1)}([function(t,e,n){!function(e,n){var r=function(t,e){"use strict";if(!e.getElementsByClassName)return;var n,r,i=e.documentElement,o=t.Date,s=t.HTMLPictureElement,a=t.addEventListener,u=t.setTimeout,c=t.requestAnimationFrame||u,l=t.requestIdleCallback,h=/^picture$/i,f=["load","error","lazyincluded","_lazyloaded"],d={},p=Array.prototype.forEach,g=function(t,e){return d[e]||(d[e]=new RegExp("(\\s|^)"+e+"(\\s|$)")),d[e].test(t.getAttribute("class")||"")&&d[e]},m=function(t,e){g(t,e)||t.setAttribute("class",(t.getAttribute("class")||"").trim()+" "+e)},y=function(t,e){var n;(n=g(t,e))&&t.setAttribute("class",(t.getAttribute("class")||"").replace(n," "))},v=function(t,e,n){var r=n?"addEventListener":"removeEventListener";n&&v(t,e),f.forEach((function(n){t[r](n,e)}))},b=function(t,r,i,o,s){var a=e.createEvent("Event");return i||(i={}),i.instance=n,a.initEvent(r,!o,!s),a.detail=i,t.dispatchEvent(a),a},w=function(e,n){var i;!s&&(i=t.picturefill||r.pf)?(n&&n.src&&!e.getAttribute("srcset")&&e.setAttribute("srcset",n.src),i({reevaluate:!0,elements:[e]})):n&&n.src&&(e.src=n.src)},_=function(t,e){return(getComputedStyle(t,null)||{})[e]},x=function(t,e,n){for(n=n||t.offsetWidth;n<r.minSize&&e&&!t._lazysizesWidth;)n=e.offsetWidth,e=e.parentNode;return n},S=(k=[],O=[],N=k,j=function(){var t=N;for(N=k.length?O:k,E=!0,T=!1;t.length;)t.shift()();E=!1},I=function(t,n){E&&!n?t.apply(this,arguments):(N.push(t),T||(T=!0,(e.hidden?u:c)(j)))},I._lsFlush=j,I),C=function(t,e){return e?function(){S(t)}:function(){var e=this,n=arguments;S((function(){t.apply(e,n)}))}},A=function(t){var e,n,r=function(){e=null,t()},i=function(){var t=o.now()-n;t<99?u(i,99-t):(l||r)(r)};return function(){n=o.now(),e||(e=u(i,99))}};var E,T,k,O,N,j,I;!function(){var e,n={lazyClass:"lazyload",loadedClass:"lazyloaded",loadingClass:"lazyloading",preloadClass:"lazypreload",errorClass:"lazyerror",autosizesClass:"lazyautosizes",srcAttr:"data-src",srcsetAttr:"data-srcset",sizesAttr:"data-sizes",minSize:40,customMedia:{},init:!0,expFactor:1.5,hFac:.8,loadMode:2,loadHidden:!0,ricTimeout:0,throttleDelay:125};for(e in r=t.lazySizesConfig||t.lazysizesConfig||{},n)e in r||(r[e]=n[e]);t.lazySizesConfig=r,u((function(){r.init&&P()}))}();var R=(Z=/^img$/i,Y=/^iframe$/i,tt="onscroll"in t&&!/(gle|ing)bot/.test(navigator.userAgent),et=0,nt=0,rt=-1,it=function(t){nt--,(!t||nt<0||!t.target)&&(nt=0)},ot=function(t){return null==G&&(G="hidden"==_(e.body,"visibility")),G||"hidden"!=_(t.parentNode,"visibility")&&"hidden"!=_(t,"visibility")},st=function(t,n){var r,o=t,s=ot(t);for(J-=n,Q+=n,W-=n,X+=n;s&&(o=o.offsetParent)&&o!=e.body&&o!=i;)(s=(_(o,"opacity")||1)>0)&&"visible"!=_(o,"overflow")&&(r=o.getBoundingClientRect(),s=X>r.left&&W<r.right&&Q>r.top-1&&J<r.bottom+1);return s},at=function(){var t,o,s,a,u,c,l,h,f,d,p,g,m=n.elements;if((B=r.loadMode)&&nt<8&&(t=m.length)){for(o=0,rt++,d=!r.expand||r.expand<1?i.clientHeight>500&&i.clientWidth>500?500:370:r.expand,n._defEx=d,p=d*r.expFactor,g=r.hFac,G=null,et<p&&nt<1&&rt>2&&B>2&&!e.hidden?(et=p,rt=0):et=B>1&&rt>1&&nt<6?d:0;o<t;o++)if(m[o]&&!m[o]._lazyRace)if(tt)if((h=m[o].getAttribute("data-expand"))&&(c=1*h)||(c=et),f!==c&&(V=innerWidth+c*g,K=innerHeight+c,l=-1*c,f=c),s=m[o].getBoundingClientRect(),(Q=s.bottom)>=l&&(J=s.top)<=K&&(X=s.right)>=l*g&&(W=s.left)<=V&&(Q||X||W||J)&&(r.loadHidden||ot(m[o]))&&(F&&nt<3&&!h&&(B<3||rt<4)||st(m[o],c))){if(pt(m[o]),u=!0,nt>9)break}else!u&&F&&!a&&nt<4&&rt<4&&B>2&&(H[0]||r.preloadAfterLoad)&&(H[0]||!h&&(Q||X||W||J||"auto"!=m[o].getAttribute(r.sizesAttr)))&&(a=H[0]||m[o]);else pt(m[o]);a&&!u&&pt(a)}},ut=function(t){var e,n=0,i=r.throttleDelay,s=r.ricTimeout,a=function(){e=!1,n=o.now(),t()},c=l&&s>49?function(){l(a,{timeout:s}),s!==r.ricTimeout&&(s=r.ricTimeout)}:C((function(){u(a)}),!0);return function(t){var r;(t=!0===t)&&(s=33),e||(e=!0,(r=i-(o.now()-n))<0&&(r=0),t||r<9?c():u(c,r))}}(at),ct=function(t){var e=t.target;e._lazyCache?delete e._lazyCache:(it(t),m(e,r.loadedClass),y(e,r.loadingClass),v(e,ht),b(e,"lazyloaded"))},lt=C(ct),ht=function(t){lt({target:t.target})},ft=function(t){var e,n=t.getAttribute(r.srcsetAttr);(e=r.customMedia[t.getAttribute("data-media")||t.getAttribute("media")])&&t.setAttribute("media",e),n&&t.setAttribute("srcset",n)},dt=C((function(t,e,n,i,o){var s,a,c,l,f,d;(f=b(t,"lazybeforeunveil",e)).defaultPrevented||(i&&(n?m(t,r.autosizesClass):t.setAttribute("sizes",i)),a=t.getAttribute(r.srcsetAttr),s=t.getAttribute(r.srcAttr),o&&(l=(c=t.parentNode)&&h.test(c.nodeName||"")),d=e.firesLoad||"src"in t&&(a||s||l),f={target:t},m(t,r.loadingClass),d&&(clearTimeout(z),z=u(it,2500),v(t,ht,!0)),l&&p.call(c.getElementsByTagName("source"),ft),a?t.setAttribute("srcset",a):s&&!l&&(Y.test(t.nodeName)?function(t,e){try{t.contentWindow.location.replace(e)}catch(n){t.src=e}}(t,s):t.src=s),o&&(a||l)&&w(t,{src:s})),t._lazyRace&&delete t._lazyRace,y(t,r.lazyClass),S((function(){var e=t.complete&&t.naturalWidth>1;d&&!e||(e&&m(t,"ls-is-cached"),ct(f),t._lazyCache=!0,u((function(){"_lazyCache"in t&&delete t._lazyCache}),9))}),!0)})),pt=function(t){var e,n=Z.test(t.nodeName),i=n&&(t.getAttribute(r.sizesAttr)||t.getAttribute("sizes")),o="auto"==i;(!o&&F||!n||!t.getAttribute("src")&&!t.srcset||t.complete||g(t,r.errorClass)||!g(t,r.lazyClass))&&(e=b(t,"lazyunveilread").detail,o&&L.updateElem(t,!0,t.offsetWidth),t._lazyRace=!0,nt++,dt(t,e,o,i,n))},gt=function(){if(!F)if(o.now()-U<999)u(gt,999);else{var t=A((function(){r.loadMode=3,ut()}));F=!0,r.loadMode=3,ut(),a("scroll",(function(){3==r.loadMode&&(r.loadMode=2),t()}),!0)}},{_:function(){U=o.now(),n.elements=e.getElementsByClassName(r.lazyClass),H=e.getElementsByClassName(r.lazyClass+" "+r.preloadClass),a("scroll",ut,!0),a("resize",ut,!0),t.MutationObserver?new MutationObserver(ut).observe(i,{childList:!0,subtree:!0,attributes:!0}):(i.addEventListener("DOMNodeInserted",ut,!0),i.addEventListener("DOMAttrModified",ut,!0),setInterval(ut,999)),a("hashchange",ut,!0),["focus","mouseover","click","load","transitionend","animationend","webkitAnimationEnd"].forEach((function(t){e.addEventListener(t,ut,!0)})),/d$|^c/.test(e.readyState)?gt():(a("load",gt),e.addEventListener("DOMContentLoaded",ut),u(gt,2e4)),n.elements.length?(at(),S._lsFlush()):ut()},checkElems:ut,unveil:pt}),L=($=C((function(t,e,n,r){var i,o,s;if(t._lazysizesWidth=r,r+="px",t.setAttribute("sizes",r),h.test(e.nodeName||""))for(o=0,s=(i=e.getElementsByTagName("source")).length;o<s;o++)i[o].setAttribute("sizes",r);n.detail.dataAttr||w(t,n.detail)})),q=function(t,e,n){var r,i=t.parentNode;i&&(n=x(t,i,n),(r=b(t,"lazybeforesizes",{width:n,dataAttr:!!e})).defaultPrevented||(n=r.detail.width)&&n!==t._lazysizesWidth&&$(t,i,r,n))},M=A((function(){var t,e=D.length;if(e)for(t=0;t<e;t++)q(D[t])})),{_:function(){D=e.getElementsByClassName(r.autosizesClass),a("resize",M)},checkElems:M,updateElem:q}),P=function(){P.i||(P.i=!0,L._(),R._())};var D,$,q,M;var H,F,z,B,U,V,K,J,W,X,Q,G,Z,Y,tt,et,nt,rt,it,ot,st,at,ut,ct,lt,ht,ft,dt,pt,gt;return n={cfg:r,autoSizer:L,loader:R,init:P,uP:w,aC:m,rC:y,hC:g,fire:b,gW:x,rAF:S}}(e,e.document);e.lazySizes=r,t.exports&&(t.exports=r)}(window)},function(t,e,n){"use strict";n.r(e);n(3),n(4),n(6),n(7),n(9),n(11),n(12),n(14),n(15),n(16);n(2)},function(t,e,n){},function(t,e,n){},function(t,e,n){function r(t,e){t.setAttribute("class","copied bg-primary-color-dark f6 absolute top-0 right-0 lh-solid hover-bg-primary-color-dark bn white ph3 pv2"),t.setAttribute("aria-label",e)}new(n(5))(".copy",{target:function(t){return t.classList.contains("copy-toggle")?t.previousElementSibling:t.nextElementSibling}}).on("success",(function(t){r(t.trigger,"Copied!"),t.clearSelection()})).on("error",(function(t){r(t.trigger,function(t,e){var n="",r="cut"===e?"X":"C";n=isMac?"Press ⌘-"+r:"Press Ctrl-"+r;return n}(t.action))}))},function(t,e,n){
/*!
* clipboard.js v2.0.4
* https://zenorocha.github.io/clipboard.js
*
* Licensed MIT © Zeno Rocha
*/
-var r;r=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=c(n(1)),o=c(n(3)),a=c(n(4));function c(e){return e&&e.__esModule?e:{default:e}}var u=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.resolveOptions(n),r.listenClick(e),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"resolveOptions",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.action="function"==typeof e.action?e.action:this.defaultAction,this.target="function"==typeof e.target?e.target:this.defaultTarget,this.text="function"==typeof e.text?e.text:this.defaultText,this.container="object"===r(e.container)?e.container:document.body}},{key:"listenClick",value:function(e){var t=this;this.listener=(0,a.default)(e,"click",(function(e){return t.onClick(e)}))}},{key:"onClick",value:function(e){var t=e.delegateTarget||e.currentTarget;this.clipboardAction&&(this.clipboardAction=null),this.clipboardAction=new s.default({action:this.action(t),target:this.target(t),text:this.text(t),container:this.container,trigger:t,emitter:this})}},{key:"defaultAction",value:function(e){return l("action",e)}},{key:"defaultTarget",value:function(e){var t=l("target",e);if(t)return document.querySelector(t)}},{key:"defaultText",value:function(e){return l("text",e)}},{key:"destroy",value:function(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],[{key:"isSupported",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["copy","cut"],t="string"==typeof e?[e]:e,n=!!document.queryCommandSupported;return t.forEach((function(e){n=n&&!!document.queryCommandSupported(e)})),n}}]),t}(o.default);function l(e,t){var n="data-clipboard-"+e;if(t.hasAttribute(n))return t.getAttribute(n)}e.exports=u},function(e,t,n){"use strict";var r,i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=n(2),a=(r=o)&&r.__esModule?r:{default:r},c=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.resolveOptions(t),this.initSelection()}return s(e,[{key:"resolveOptions",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.action=e.action,this.container=e.container,this.emitter=e.emitter,this.target=e.target,this.text=e.text,this.trigger=e.trigger,this.selectedText=""}},{key:"initSelection",value:function(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"selectFake",value:function(){var e=this,t="rtl"==document.documentElement.getAttribute("dir");this.removeFake(),this.fakeHandlerCallback=function(){return e.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[t?"right":"left"]="-9999px";var n=window.pageYOffset||document.documentElement.scrollTop;this.fakeElem.style.top=n+"px",this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.container.appendChild(this.fakeElem),this.selectedText=(0,a.default)(this.fakeElem),this.copyText()}},{key:"removeFake",value:function(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function(){this.selectedText=(0,a.default)(this.target),this.copyText()}},{key:"copyText",value:function(){var e=void 0;try{e=document.execCommand(this.action)}catch(t){e=!1}this.handleResult(e)}},{key:"handleResult",value:function(e){this.emitter.emit(e?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function(){this.trigger&&this.trigger.focus(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function(){this.removeFake()}},{key:"action",set:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"copy";if(this._action=e,"copy"!==this._action&&"cut"!==this._action)throw new Error('Invalid "action" value, use either "copy" or "cut"')},get:function(){return this._action}},{key:"target",set:function(e){if(void 0!==e){if(!e||"object"!==(void 0===e?"undefined":i(e))||1!==e.nodeType)throw new Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&e.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(e.hasAttribute("readonly")||e.hasAttribute("disabled")))throw new Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=e}},get:function(){return this._target}}]),e}();e.exports=c},function(e,t){e.exports=function(e){var t;if("SELECT"===e.nodeName)e.focus(),t=e.value;else if("INPUT"===e.nodeName||"TEXTAREA"===e.nodeName){var n=e.hasAttribute("readonly");n||e.setAttribute("readonly",""),e.select(),e.setSelectionRange(0,e.value.length),n||e.removeAttribute("readonly"),t=e.value}else{e.hasAttribute("contenteditable")&&e.focus();var r=window.getSelection(),i=document.createRange();i.selectNodeContents(e),r.removeAllRanges(),r.addRange(i),t=r.toString()}return t}},function(e,t){function n(){}n.prototype={on:function(e,t,n){var r=this.e||(this.e={});return(r[e]||(r[e]=[])).push({fn:t,ctx:n}),this},once:function(e,t,n){var r=this;function i(){r.off(e,i),t.apply(n,arguments)}return i._=t,this.on(e,i,n)},emit:function(e){for(var t=[].slice.call(arguments,1),n=((this.e||(this.e={}))[e]||[]).slice(),r=0,i=n.length;r<i;r++)n[r].fn.apply(n[r].ctx,t);return this},off:function(e,t){var n=this.e||(this.e={}),r=n[e],i=[];if(r&&t)for(var s=0,o=r.length;s<o;s++)r[s].fn!==t&&r[s].fn._!==t&&i.push(r[s]);return i.length?n[e]=i:delete n[e],this}},e.exports=n},function(e,t,n){var r=n(5),i=n(6);e.exports=function(e,t,n){if(!e&&!t&&!n)throw new Error("Missing required arguments");if(!r.string(t))throw new TypeError("Second argument must be a String");if(!r.fn(n))throw new TypeError("Third argument must be a Function");if(r.node(e))return function(e,t,n){return e.addEventListener(t,n),{destroy:function(){e.removeEventListener(t,n)}}}(e,t,n);if(r.nodeList(e))return function(e,t,n){return Array.prototype.forEach.call(e,(function(e){e.addEventListener(t,n)})),{destroy:function(){Array.prototype.forEach.call(e,(function(e){e.removeEventListener(t,n)}))}}}(e,t,n);if(r.string(e))return function(e,t,n){return i(document.body,e,t,n)}(e,t,n);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}},function(e,t){t.node=function(e){return void 0!==e&&e instanceof HTMLElement&&1===e.nodeType},t.nodeList=function(e){var n=Object.prototype.toString.call(e);return void 0!==e&&("[object NodeList]"===n||"[object HTMLCollection]"===n)&&"length"in e&&(0===e.length||t.node(e[0]))},t.string=function(e){return"string"==typeof e||e instanceof String},t.fn=function(e){return"[object Function]"===Object.prototype.toString.call(e)}},function(e,t,n){var r=n(7);function i(e,t,n,r,i){var o=s.apply(this,arguments);return e.addEventListener(n,o,i),{destroy:function(){e.removeEventListener(n,o,i)}}}function s(e,t,n,i){return function(n){n.delegateTarget=r(n.target,t),n.delegateTarget&&i.call(e,n)}}e.exports=function(e,t,n,r,s){return"function"==typeof e.addEventListener?i.apply(null,arguments):"function"==typeof n?i.bind(null,document).apply(null,arguments):("string"==typeof e&&(e=document.querySelectorAll(e)),Array.prototype.map.call(e,(function(e){return i(e,t,n,r,s)})))}},function(e,t){if("undefined"!=typeof Element&&!Element.prototype.matches){var n=Element.prototype;n.matches=n.matchesSelector||n.mozMatchesSelector||n.msMatchesSelector||n.oMatchesSelector||n.webkitMatchesSelector}e.exports=function(e,t){for(;e&&9!==e.nodeType;){if("function"==typeof e.matches&&e.matches(t))return e;e=e.parentNode}}}])},e.exports=r()},function(e,t){let n=document.getElementById("prose");if(n){let e=n.getElementsByTagName("code");for(let[t,n]of Object.entries(e)){n.scrollWidth-n.clientWidth>0&&n.parentNode.classList.add("expand")}}},function(e,t,n){n(8)({apiKey:"167e7998590aebda7f9fedcf86bc4a55",indexName:"hugodocs",inputSelector:"#search-input",debug:!0})},function(e,t,n){
+var r;r=function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=0)}([function(t,e,n){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),o=u(n(1)),s=u(n(3)),a=u(n(4));function u(t){return t&&t.__esModule?t:{default:t}}var c=function(t){function e(t,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this));return r.resolveOptions(n),r.listenClick(t),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),i(e,[{key:"resolveOptions",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.action="function"==typeof t.action?t.action:this.defaultAction,this.target="function"==typeof t.target?t.target:this.defaultTarget,this.text="function"==typeof t.text?t.text:this.defaultText,this.container="object"===r(t.container)?t.container:document.body}},{key:"listenClick",value:function(t){var e=this;this.listener=(0,a.default)(t,"click",(function(t){return e.onClick(t)}))}},{key:"onClick",value:function(t){var e=t.delegateTarget||t.currentTarget;this.clipboardAction&&(this.clipboardAction=null),this.clipboardAction=new o.default({action:this.action(e),target:this.target(e),text:this.text(e),container:this.container,trigger:e,emitter:this})}},{key:"defaultAction",value:function(t){return l("action",t)}},{key:"defaultTarget",value:function(t){var e=l("target",t);if(e)return document.querySelector(e)}},{key:"defaultText",value:function(t){return l("text",t)}},{key:"destroy",value:function(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],[{key:"isSupported",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["copy","cut"],e="string"==typeof t?[t]:t,n=!!document.queryCommandSupported;return e.forEach((function(t){n=n&&!!document.queryCommandSupported(t)})),n}}]),e}(s.default);function l(t,e){var n="data-clipboard-"+t;if(e.hasAttribute(n))return e.getAttribute(n)}t.exports=c},function(t,e,n){"use strict";var r,i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=n(2),a=(r=s)&&r.__esModule?r:{default:r},u=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.resolveOptions(e),this.initSelection()}return o(t,[{key:"resolveOptions",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.action=t.action,this.container=t.container,this.emitter=t.emitter,this.target=t.target,this.text=t.text,this.trigger=t.trigger,this.selectedText=""}},{key:"initSelection",value:function(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"selectFake",value:function(){var t=this,e="rtl"==document.documentElement.getAttribute("dir");this.removeFake(),this.fakeHandlerCallback=function(){return t.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[e?"right":"left"]="-9999px";var n=window.pageYOffset||document.documentElement.scrollTop;this.fakeElem.style.top=n+"px",this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.container.appendChild(this.fakeElem),this.selectedText=(0,a.default)(this.fakeElem),this.copyText()}},{key:"removeFake",value:function(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function(){this.selectedText=(0,a.default)(this.target),this.copyText()}},{key:"copyText",value:function(){var t=void 0;try{t=document.execCommand(this.action)}catch(e){t=!1}this.handleResult(t)}},{key:"handleResult",value:function(t){this.emitter.emit(t?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function(){this.trigger&&this.trigger.focus(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function(){this.removeFake()}},{key:"action",set:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"copy";if(this._action=t,"copy"!==this._action&&"cut"!==this._action)throw new Error('Invalid "action" value, use either "copy" or "cut"')},get:function(){return this._action}},{key:"target",set:function(t){if(void 0!==t){if(!t||"object"!==(void 0===t?"undefined":i(t))||1!==t.nodeType)throw new Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&t.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(t.hasAttribute("readonly")||t.hasAttribute("disabled")))throw new Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=t}},get:function(){return this._target}}]),t}();t.exports=u},function(t,e){t.exports=function(t){var e;if("SELECT"===t.nodeName)t.focus(),e=t.value;else if("INPUT"===t.nodeName||"TEXTAREA"===t.nodeName){var n=t.hasAttribute("readonly");n||t.setAttribute("readonly",""),t.select(),t.setSelectionRange(0,t.value.length),n||t.removeAttribute("readonly"),e=t.value}else{t.hasAttribute("contenteditable")&&t.focus();var r=window.getSelection(),i=document.createRange();i.selectNodeContents(t),r.removeAllRanges(),r.addRange(i),e=r.toString()}return e}},function(t,e){function n(){}n.prototype={on:function(t,e,n){var r=this.e||(this.e={});return(r[t]||(r[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){var r=this;function i(){r.off(t,i),e.apply(n,arguments)}return i._=e,this.on(t,i,n)},emit:function(t){for(var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),r=0,i=n.length;r<i;r++)n[r].fn.apply(n[r].ctx,e);return this},off:function(t,e){var n=this.e||(this.e={}),r=n[t],i=[];if(r&&e)for(var o=0,s=r.length;o<s;o++)r[o].fn!==e&&r[o].fn._!==e&&i.push(r[o]);return i.length?n[t]=i:delete n[t],this}},t.exports=n},function(t,e,n){var r=n(5),i=n(6);t.exports=function(t,e,n){if(!t&&!e&&!n)throw new Error("Missing required arguments");if(!r.string(e))throw new TypeError("Second argument must be a String");if(!r.fn(n))throw new TypeError("Third argument must be a Function");if(r.node(t))return function(t,e,n){return t.addEventListener(e,n),{destroy:function(){t.removeEventListener(e,n)}}}(t,e,n);if(r.nodeList(t))return function(t,e,n){return Array.prototype.forEach.call(t,(function(t){t.addEventListener(e,n)})),{destroy:function(){Array.prototype.forEach.call(t,(function(t){t.removeEventListener(e,n)}))}}}(t,e,n);if(r.string(t))return function(t,e,n){return i(document.body,t,e,n)}(t,e,n);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}},function(t,e){e.node=function(t){return void 0!==t&&t instanceof HTMLElement&&1===t.nodeType},e.nodeList=function(t){var n=Object.prototype.toString.call(t);return void 0!==t&&("[object NodeList]"===n||"[object HTMLCollection]"===n)&&"length"in t&&(0===t.length||e.node(t[0]))},e.string=function(t){return"string"==typeof t||t instanceof String},e.fn=function(t){return"[object Function]"===Object.prototype.toString.call(t)}},function(t,e,n){var r=n(7);function i(t,e,n,r,i){var s=o.apply(this,arguments);return t.addEventListener(n,s,i),{destroy:function(){t.removeEventListener(n,s,i)}}}function o(t,e,n,i){return function(n){n.delegateTarget=r(n.target,e),n.delegateTarget&&i.call(t,n)}}t.exports=function(t,e,n,r,o){return"function"==typeof t.addEventListener?i.apply(null,arguments):"function"==typeof n?i.bind(null,document).apply(null,arguments):("string"==typeof t&&(t=document.querySelectorAll(t)),Array.prototype.map.call(t,(function(t){return i(t,e,n,r,o)})))}},function(t,e){if("undefined"!=typeof Element&&!Element.prototype.matches){var n=Element.prototype;n.matches=n.matchesSelector||n.mozMatchesSelector||n.msMatchesSelector||n.oMatchesSelector||n.webkitMatchesSelector}t.exports=function(t,e){for(;t&&9!==t.nodeType;){if("function"==typeof t.matches&&t.matches(e))return t;t=t.parentNode}}}])},t.exports=r()},function(t,e){let n=document.getElementById("prose");if(n){let t=n.getElementsByTagName("code");for(let[e,n]of Object.entries(t)){n.scrollWidth-n.clientWidth>0&&n.parentNode.classList.add("expand")}}},function(t,e,n){n(8)({apiKey:"167e7998590aebda7f9fedcf86bc4a55",indexName:"hugodocs",inputSelector:"#search-input",debug:!0})},function(t,e,n){
/*! docsearch 2.6.1 | © Algolia | github.com/algolia/docsearch */
-var r;"undefined"!=typeof self&&self,r=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=22)}([function(e,t,n){"use strict";var r,i=n(1);function s(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}e.exports={isArray:null,isFunction:null,isObject:null,bind:null,each:null,map:null,mixin:null,isMsie:function(e){if(void 0===e&&(e=navigator.userAgent),/(msie|trident)/i.test(e)){var t=e.match(/(msie |rv:)(\d+(.\d+)?)/i);if(t)return t[2]}return!1},escapeRegExChars:function(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")},isNumber:function(e){return"number"==typeof e},toStr:function(e){return null==e?"":e+""},cloneDeep:function(e){var t=this.mixin({},e),n=this;return this.each(t,(function(e,r){e&&(n.isArray(e)?t[r]=[].concat(e):n.isObject(e)&&(t[r]=n.cloneDeep(e)))})),t},error:function(e){throw new Error(e)},every:function(e,t){var n=!0;return e?(this.each(e,(function(r,i){if(!(n=t.call(null,r,i,e)))return!1})),!!n):n},any:function(e,t){var n=!1;return e?(this.each(e,(function(r,i){if(t.call(null,r,i,e))return n=!0,!1})),n):n},getUniqueId:(r=0,function(){return r++}),templatify:function(e){if(this.isFunction(e))return e;var t=i.element(e);return"SCRIPT"===t.prop("tagName")?function(){return t.text()}:function(){return String(e)}},defer:function(e){setTimeout(e,0)},noop:function(){},formatPrefix:function(e,t){return t?"":e+"-"},className:function(e,t,n){return(n?"":".")+e+t},escapeHighlightedString:function(e,t,n){t=t||"<em>";var r=document.createElement("div");r.appendChild(document.createTextNode(t)),n=n||"</em>";var i=document.createElement("div");i.appendChild(document.createTextNode(n));var o=document.createElement("div");return o.appendChild(document.createTextNode(e)),o.innerHTML.replace(RegExp(s(r.innerHTML),"g"),t).replace(RegExp(s(i.innerHTML),"g"),n)}}},function(e,t,n){"use strict";e.exports={element:null}},function(e,t){var n=Object.prototype.hasOwnProperty,r=Object.prototype.toString;e.exports=function(e,t,i){if("[object Function]"!==r.call(t))throw new TypeError("iterator must be a function");var s=e.length;if(s===+s)for(var o=0;o<s;o++)t.call(i,e[o],o,e);else for(var a in e)n.call(e,a)&&t.call(i,e[a],a,e)}},function(e,t){e.exports=function(e){return JSON.parse(JSON.stringify(e))}},function(e,t){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";var r=n(12);function i(e,t){var r=n(2),i=this;"function"==typeof Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):i.stack=(new Error).stack||"Cannot get a stacktrace, browser is too old",this.name="AlgoliaSearchError",this.message=e||"Unknown error",t&&r(t,(function(e,t){i[t]=e}))}function s(e,t){function n(){var n=Array.prototype.slice.call(arguments,0);"string"!=typeof n[0]&&n.unshift(t),i.apply(this,n),this.name="AlgoliaSearch"+e+"Error"}return r(n,i),n}r(i,Error),e.exports={AlgoliaSearchError:i,UnparsableJSON:s("UnparsableJSON","Could not parse the incoming response as JSON, see err.more for details"),RequestTimeout:s("RequestTimeout","Request timedout before getting a response"),Network:s("Network","Network issue, see err.more for details"),JSONPScriptFail:s("JSONPScriptFail","<script> was loaded but did not call our provided callback"),JSONPScriptError:s("JSONPScriptError","<script> unable to load due to an `error` event on it"),Unknown:s("Unknown","Unknown error occured")}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){var r=n(2);e.exports=function(e,t){var n=[];return r(e,(function(r,i){n.push(t(r,i,e))})),n}},function(e,t,n){(function(r){function i(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=Object({NODE_ENV:"production"}).DEBUG),e}(t=e.exports=n(39)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,s=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(i++,"%c"===e&&(s=i))})),e.splice(s,0,r)}},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=i,t.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(i())}).call(t,n(9))},function(e,t){var n,r,i=e.exports={};function s(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function a(e){if(n===setTimeout)return setTimeout(e,0);if((n===s||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:s}catch(e){n=s}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(e){r=o}}();var c,u=[],l=!1,h=-1;function d(){l&&c&&(l=!1,c.length?u=c.concat(u):h=-1,u.length&&f())}function f(){if(!l){var e=a(d);l=!0;for(var t=u.length;t;){for(c=u,u=[];++h<t;)c&&c[h].run();h=-1,t=u.length}c=null,l=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===o||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function p(e,t){this.fun=e,this.array=t}function g(){}i.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new p(e,t)),1!==u.length||l||a(f)},p.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=g,i.addListener=g,i.once=g,i.off=g,i.removeListener=g,i.removeAllListeners=g,i.emit=g,i.prependListener=g,i.prependOnceListener=g,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(e,t,n){"use strict";var r=n(53),i=/\s+/;function s(e,t,n,r){var s;if(!n)return this;for(t=t.split(i),n=r?function(e,t){return e.bind?e.bind(t):function(){e.apply(t,[].slice.call(arguments,0))}}(n,r):n,this._callbacks=this._callbacks||{};s=t.shift();)this._callbacks[s]=this._callbacks[s]||{sync:[],async:[]},this._callbacks[s][e].push(n);return this}function o(e,t,n){return function(){for(var r,i=0,s=e.length;!r&&i<s;i+=1)r=!1===e[i].apply(t,n);return!r}}e.exports={onSync:function(e,t,n){return s.call(this,"sync",e,t,n)},onAsync:function(e,t,n){return s.call(this,"async",e,t,n)},off:function(e){var t;if(!this._callbacks)return this;for(e=e.split(i);t=e.shift();)delete this._callbacks[t];return this},trigger:function(e){var t,n,s,a,c;if(!this._callbacks)return this;for(e=e.split(i),s=[].slice.call(arguments,1);(t=e.shift())&&(n=this._callbacks[t]);)a=o(n.sync,this,[t].concat(s)),c=o(n.async,this,[t].concat(s)),a()&&r(c);return this}}},function(e,t,n){"use strict";var r=n(0),i={wrapper:{position:"relative",display:"inline-block"},hint:{position:"absolute",top:"0",left:"0",borderColor:"transparent",boxShadow:"none",opacity:"1"},input:{position:"relative",verticalAlign:"top",backgroundColor:"transparent"},inputWithNoHint:{position:"relative",verticalAlign:"top"},dropdown:{position:"absolute",top:"100%",left:"0",zIndex:"100",display:"none"},suggestions:{display:"block"},suggestion:{whiteSpace:"nowrap",cursor:"pointer"},suggestionChild:{whiteSpace:"normal"},ltr:{left:"0",right:"auto"},rtl:{left:"auto",right:"0"},defaultClasses:{root:"algolia-autocomplete",prefix:"aa",noPrefix:!1,dropdownMenu:"dropdown-menu",input:"input",hint:"hint",suggestions:"suggestions",suggestion:"suggestion",cursor:"cursor",dataset:"dataset",empty:"empty"},appendTo:{wrapper:{position:"absolute",zIndex:"100",display:"none"},input:{},inputWithNoHint:{},dropdown:{display:"block"}}};r.isMsie()&&r.mixin(i.input,{backgroundImage:"url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)"}),r.isMsie()&&r.isMsie()<=7&&r.mixin(i.input,{marginTop:"-1px"}),e.exports=i},function(e,t){"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t,n){e.exports=function(e,t){return function(n,i,s){if("function"==typeof n&&"object"==typeof i||"object"==typeof s)throw new r.AlgoliaSearchError("index.search usage is index.search(query, params, cb)");0===arguments.length||"function"==typeof n?(s=n,n=""):1!==arguments.length&&"function"!=typeof i||(s=i,i=void 0),"object"==typeof n&&null!==n?(i=n,n=void 0):null==n&&(n="");var o,a="";return void 0!==n&&(a+=e+"="+encodeURIComponent(n)),void 0!==i&&(i.additionalUA&&(o=i.additionalUA,delete i.additionalUA),a=this.as._getSearchParams(i,a)),this._search(a,t,s,o)}};var r=n(5)},function(e,t,n){e.exports=function(e,t){var r=n(36),i=n(2),s={};return i(r(e),(function(n){!0!==t(n)&&(s[n]=e[n])})),s}},function(e,t){var n;n=window,e.exports=function(e){var t,n,r=function(){var t,n,r,i,s,o=[],a=o.concat,c=o.filter,u=o.slice,l=e.document,h={},d={},f={"column-count":1,columns:1,"font-weight":1,"line-height":1,opacity:1,"z-index":1,zoom:1},p=/^\s*<(\w+|!)[^>]*>/,g=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,m=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,v=/^(?:body|html)$/i,y=/([A-Z])/g,b=["val","css","html","text","data","width","height","offset"],w=l.createElement("table"),_=l.createElement("tr"),E={tr:l.createElement("tbody"),tbody:w,thead:w,tfoot:w,td:_,th:_,"*":l.createElement("div")},x=/complete|loaded|interactive/,S=/^[\w-]*$/,C={},A=C.toString,N={},O=l.createElement("div"),T={tabindex:"tabIndex",readonly:"readOnly",for:"htmlFor",class:"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},k=Array.isArray||function(e){return e instanceof Array};function R(e){return null==e?String(e):C[A.call(e)]||"object"}function M(e){return"function"==R(e)}function L(e){return null!=e&&e==e.window}function I(e){return null!=e&&e.nodeType==e.DOCUMENT_NODE}function D(e){return"object"==R(e)}function j(e){return D(e)&&!L(e)&&Object.getPrototypeOf(e)==Object.prototype}function P(e){var t=!!e&&"length"in e&&e.length,r=n.type(e);return"function"!=r&&!L(e)&&("array"==r||0===t||"number"==typeof t&&t>0&&t-1 in e)}function $(e){return e.replace(/::/g,"/").replace(/([A-Z]+)([A-Z][a-z])/g,"$1_$2").replace(/([a-z\d])([A-Z])/g,"$1_$2").replace(/_/g,"-").toLowerCase()}function H(e){return e in d?d[e]:d[e]=new RegExp("(^|\\s)"+e+"(\\s|$)")}function B(e,t){return"number"!=typeof t||f[$(e)]?t:t+"px"}function q(e){return"children"in e?u.call(e.children):n.map(e.childNodes,(function(e){if(1==e.nodeType)return e}))}function F(e,t){var n,r=e?e.length:0;for(n=0;n<r;n++)this[n]=e[n];this.length=r,this.selector=t||""}function z(e,n,r){for(t in n)r&&(j(n[t])||k(n[t]))?(j(n[t])&&!j(e[t])&&(e[t]={}),k(n[t])&&!k(e[t])&&(e[t]=[]),z(e[t],n[t],r)):void 0!==n[t]&&(e[t]=n[t])}function U(e,t){return null==t?n(e):n(e).filter(t)}function K(e,t,n,r){return M(t)?t.call(e,n,r):t}function V(e,t,n){null==n?e.removeAttribute(t):e.setAttribute(t,n)}function J(e,t){var n=e.className||"",r=n&&void 0!==n.baseVal;if(void 0===t)return r?n.baseVal:n;r?n.baseVal=t:e.className=t}function W(e){try{return e?"true"==e||"false"!=e&&("null"==e?null:+e+""==e?+e:/^[\[\{]/.test(e)?n.parseJSON(e):e):e}catch(t){return e}}function G(e,t){t(e);for(var n=0,r=e.childNodes.length;n<r;n++)G(e.childNodes[n],t)}return N.matches=function(e,t){if(!t||!e||1!==e.nodeType)return!1;var n=e.matches||e.webkitMatchesSelector||e.mozMatchesSelector||e.oMatchesSelector||e.matchesSelector;if(n)return n.call(e,t);var r,i=e.parentNode,s=!i;return s&&(i=O).appendChild(e),r=~N.qsa(i,t).indexOf(e),s&&O.removeChild(e),r},i=function(e){return e.replace(/-+(.)?/g,(function(e,t){return t?t.toUpperCase():""}))},s=function(e){return c.call(e,(function(t,n){return e.indexOf(t)==n}))},N.fragment=function(e,t,r){var i,s,o;return g.test(e)&&(i=n(l.createElement(RegExp.$1))),i||(e.replace&&(e=e.replace(m,"<$1></$2>")),void 0===t&&(t=p.test(e)&&RegExp.$1),t in E||(t="*"),(o=E[t]).innerHTML=""+e,i=n.each(u.call(o.childNodes),(function(){o.removeChild(this)}))),j(r)&&(s=n(i),n.each(r,(function(e,t){b.indexOf(e)>-1?s[e](t):s.attr(e,t)}))),i},N.Z=function(e,t){return new F(e,t)},N.isZ=function(e){return e instanceof N.Z},N.init=function(e,t){var r,i;if(!e)return N.Z();if("string"==typeof e)if("<"==(e=e.trim())[0]&&p.test(e))r=N.fragment(e,RegExp.$1,t),e=null;else{if(void 0!==t)return n(t).find(e);r=N.qsa(l,e)}else{if(M(e))return n(l).ready(e);if(N.isZ(e))return e;if(k(e))i=e,r=c.call(i,(function(e){return null!=e}));else if(D(e))r=[e],e=null;else if(p.test(e))r=N.fragment(e.trim(),RegExp.$1,t),e=null;else{if(void 0!==t)return n(t).find(e);r=N.qsa(l,e)}}return N.Z(r,e)},(n=function(e,t){return N.init(e,t)}).extend=function(e){var t,n=u.call(arguments,1);return"boolean"==typeof e&&(t=e,e=n.shift()),n.forEach((function(n){z(e,n,t)})),e},N.qsa=function(e,t){var n,r="#"==t[0],i=!r&&"."==t[0],s=r||i?t.slice(1):t,o=S.test(s);return e.getElementById&&o&&r?(n=e.getElementById(s))?[n]:[]:1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType?[]:u.call(o&&!r&&e.getElementsByClassName?i?e.getElementsByClassName(s):e.getElementsByTagName(t):e.querySelectorAll(t))},n.contains=l.documentElement.contains?function(e,t){return e!==t&&e.contains(t)}:function(e,t){for(;t&&(t=t.parentNode);)if(t===e)return!0;return!1},n.type=R,n.isFunction=M,n.isWindow=L,n.isArray=k,n.isPlainObject=j,n.isEmptyObject=function(e){var t;for(t in e)return!1;return!0},n.isNumeric=function(e){var t=Number(e),n=typeof e;return null!=e&&"boolean"!=n&&("string"!=n||e.length)&&!isNaN(t)&&isFinite(t)||!1},n.inArray=function(e,t,n){return o.indexOf.call(t,e,n)},n.camelCase=i,n.trim=function(e){return null==e?"":String.prototype.trim.call(e)},n.uuid=0,n.support={},n.expr={},n.noop=function(){},n.map=function(e,t){var r,i,s,o,a=[];if(P(e))for(i=0;i<e.length;i++)null!=(r=t(e[i],i))&&a.push(r);else for(s in e)null!=(r=t(e[s],s))&&a.push(r);return(o=a).length>0?n.fn.concat.apply([],o):o},n.each=function(e,t){var n,r;if(P(e)){for(n=0;n<e.length;n++)if(!1===t.call(e[n],n,e[n]))return e}else for(r in e)if(!1===t.call(e[r],r,e[r]))return e;return e},n.grep=function(e,t){return c.call(e,t)},e.JSON&&(n.parseJSON=JSON.parse),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),(function(e,t){C["[object "+t+"]"]=t.toLowerCase()})),n.fn={constructor:N.Z,length:0,forEach:o.forEach,reduce:o.reduce,push:o.push,sort:o.sort,splice:o.splice,indexOf:o.indexOf,concat:function(){var e,t,n=[];for(e=0;e<arguments.length;e++)t=arguments[e],n[e]=N.isZ(t)?t.toArray():t;return a.apply(N.isZ(this)?this.toArray():this,n)},map:function(e){return n(n.map(this,(function(t,n){return e.call(t,n,t)})))},slice:function(){return n(u.apply(this,arguments))},ready:function(e){return x.test(l.readyState)&&l.body?e(n):l.addEventListener("DOMContentLoaded",(function(){e(n)}),!1),this},get:function(e){return void 0===e?u.call(this):this[e>=0?e:e+this.length]},toArray:function(){return this.get()},size:function(){return this.length},remove:function(){return this.each((function(){null!=this.parentNode&&this.parentNode.removeChild(this)}))},each:function(e){return o.every.call(this,(function(t,n){return!1!==e.call(t,n,t)})),this},filter:function(e){return M(e)?this.not(this.not(e)):n(c.call(this,(function(t){return N.matches(t,e)})))},add:function(e,t){return n(s(this.concat(n(e,t))))},is:function(e){return this.length>0&&N.matches(this[0],e)},not:function(e){var t=[];if(M(e)&&void 0!==e.call)this.each((function(n){e.call(this,n)||t.push(this)}));else{var r="string"==typeof e?this.filter(e):P(e)&&M(e.item)?u.call(e):n(e);this.forEach((function(e){r.indexOf(e)<0&&t.push(e)}))}return n(t)},has:function(e){return this.filter((function(){return D(e)?n.contains(this,e):n(this).find(e).size()}))},eq:function(e){return-1===e?this.slice(e):this.slice(e,+e+1)},first:function(){var e=this[0];return e&&!D(e)?e:n(e)},last:function(){var e=this[this.length-1];return e&&!D(e)?e:n(e)},find:function(e){var t=this;return e?"object"==typeof e?n(e).filter((function(){var e=this;return o.some.call(t,(function(t){return n.contains(t,e)}))})):1==this.length?n(N.qsa(this[0],e)):this.map((function(){return N.qsa(this,e)})):n()},closest:function(e,t){var r=[],i="object"==typeof e&&n(e);return this.each((function(n,s){for(;s&&!(i?i.indexOf(s)>=0:N.matches(s,e));)s=s!==t&&!I(s)&&s.parentNode;s&&r.indexOf(s)<0&&r.push(s)})),n(r)},parents:function(e){for(var t=[],r=this;r.length>0;)r=n.map(r,(function(e){if((e=e.parentNode)&&!I(e)&&t.indexOf(e)<0)return t.push(e),e}));return U(t,e)},parent:function(e){return U(s(this.pluck("parentNode")),e)},children:function(e){return U(this.map((function(){return q(this)})),e)},contents:function(){return this.map((function(){return this.contentDocument||u.call(this.childNodes)}))},siblings:function(e){return U(this.map((function(e,t){return c.call(q(t.parentNode),(function(e){return e!==t}))})),e)},empty:function(){return this.each((function(){this.innerHTML=""}))},pluck:function(e){return n.map(this,(function(t){return t[e]}))},show:function(){return this.each((function(){var e,t,n;"none"==this.style.display&&(this.style.display=""),"none"==getComputedStyle(this,"").getPropertyValue("display")&&(this.style.display=(e=this.nodeName,h[e]||(t=l.createElement(e),l.body.appendChild(t),n=getComputedStyle(t,"").getPropertyValue("display"),t.parentNode.removeChild(t),"none"==n&&(n="block"),h[e]=n),h[e]))}))},replaceWith:function(e){return this.before(e).remove()},wrap:function(e){var t=M(e);if(this[0]&&!t)var r=n(e).get(0),i=r.parentNode||this.length>1;return this.each((function(s){n(this).wrapAll(t?e.call(this,s):i?r.cloneNode(!0):r)}))},wrapAll:function(e){if(this[0]){var t;for(n(this[0]).before(e=n(e));(t=e.children()).length;)e=t.first();n(e).append(this)}return this},wrapInner:function(e){var t=M(e);return this.each((function(r){var i=n(this),s=i.contents(),o=t?e.call(this,r):e;s.length?s.wrapAll(o):i.append(o)}))},unwrap:function(){return this.parent().each((function(){n(this).replaceWith(n(this).children())})),this},clone:function(){return this.map((function(){return this.cloneNode(!0)}))},hide:function(){return this.css("display","none")},toggle:function(e){return this.each((function(){var t=n(this);(void 0===e?"none"==t.css("display"):e)?t.show():t.hide()}))},prev:function(e){return n(this.pluck("previousElementSibling")).filter(e||"*")},next:function(e){return n(this.pluck("nextElementSibling")).filter(e||"*")},html:function(e){return 0 in arguments?this.each((function(t){var r=this.innerHTML;n(this).empty().append(K(this,e,t,r))})):0 in this?this[0].innerHTML:null},text:function(e){return 0 in arguments?this.each((function(t){var n=K(this,e,t,this.textContent);this.textContent=null==n?"":""+n})):0 in this?this.pluck("textContent").join(""):null},attr:function(e,n){var r;return"string"!=typeof e||1 in arguments?this.each((function(r){if(1===this.nodeType)if(D(e))for(t in e)V(this,t,e[t]);else V(this,e,K(this,n,r,this.getAttribute(e)))})):0 in this&&1==this[0].nodeType&&null!=(r=this[0].getAttribute(e))?r:void 0},removeAttr:function(e){return this.each((function(){1===this.nodeType&&e.split(" ").forEach((function(e){V(this,e)}),this)}))},prop:function(e,t){return e=T[e]||e,1 in arguments?this.each((function(n){this[e]=K(this,t,n,this[e])})):this[0]&&this[0][e]},removeProp:function(e){return e=T[e]||e,this.each((function(){delete this[e]}))},data:function(e,t){var n="data-"+e.replace(y,"-$1").toLowerCase(),r=1 in arguments?this.attr(n,t):this.attr(n);return null!==r?W(r):void 0},val:function(e){return 0 in arguments?(null==e&&(e=""),this.each((function(t){this.value=K(this,e,t,this.value)}))):this[0]&&(this[0].multiple?n(this[0]).find("option").filter((function(){return this.selected})).pluck("value"):this[0].value)},offset:function(t){if(t)return this.each((function(e){var r=n(this),i=K(this,t,e,r.offset()),s=r.offsetParent().offset(),o={top:i.top-s.top,left:i.left-s.left};"static"==r.css("position")&&(o.position="relative"),r.css(o)}));if(!this.length)return null;if(l.documentElement!==this[0]&&!n.contains(l.documentElement,this[0]))return{top:0,left:0};var r=this[0].getBoundingClientRect();return{left:r.left+e.pageXOffset,top:r.top+e.pageYOffset,width:Math.round(r.width),height:Math.round(r.height)}},css:function(e,r){if(arguments.length<2){var s=this[0];if("string"==typeof e){if(!s)return;return s.style[i(e)]||getComputedStyle(s,"").getPropertyValue(e)}if(k(e)){if(!s)return;var o={},a=getComputedStyle(s,"");return n.each(e,(function(e,t){o[t]=s.style[i(t)]||a.getPropertyValue(t)})),o}}var c="";if("string"==R(e))r||0===r?c=$(e)+":"+B(e,r):this.each((function(){this.style.removeProperty($(e))}));else for(t in e)e[t]||0===e[t]?c+=$(t)+":"+B(t,e[t])+";":this.each((function(){this.style.removeProperty($(t))}));return this.each((function(){this.style.cssText+=";"+c}))},index:function(e){return e?this.indexOf(n(e)[0]):this.parent().children().indexOf(this[0])},hasClass:function(e){return!!e&&o.some.call(this,(function(e){return this.test(J(e))}),H(e))},addClass:function(e){return e?this.each((function(t){if("className"in this){r=[];var i=J(this);K(this,e,t,i).split(/\s+/g).forEach((function(e){n(this).hasClass(e)||r.push(e)}),this),r.length&&J(this,i+(i?" ":"")+r.join(" "))}})):this},removeClass:function(e){return this.each((function(t){if("className"in this){if(void 0===e)return J(this,"");r=J(this),K(this,e,t,r).split(/\s+/g).forEach((function(e){r=r.replace(H(e)," ")})),J(this,r.trim())}}))},toggleClass:function(e,t){return e?this.each((function(r){var i=n(this);K(this,e,r,J(this)).split(/\s+/g).forEach((function(e){(void 0===t?!i.hasClass(e):t)?i.addClass(e):i.removeClass(e)}))})):this},scrollTop:function(e){if(this.length){var t="scrollTop"in this[0];return void 0===e?t?this[0].scrollTop:this[0].pageYOffset:this.each(t?function(){this.scrollTop=e}:function(){this.scrollTo(this.scrollX,e)})}},scrollLeft:function(e){if(this.length){var t="scrollLeft"in this[0];return void 0===e?t?this[0].scrollLeft:this[0].pageXOffset:this.each(t?function(){this.scrollLeft=e}:function(){this.scrollTo(e,this.scrollY)})}},position:function(){if(this.length){var e=this[0],t=this.offsetParent(),r=this.offset(),i=v.test(t[0].nodeName)?{top:0,left:0}:t.offset();return r.top-=parseFloat(n(e).css("margin-top"))||0,r.left-=parseFloat(n(e).css("margin-left"))||0,i.top+=parseFloat(n(t[0]).css("border-top-width"))||0,i.left+=parseFloat(n(t[0]).css("border-left-width"))||0,{top:r.top-i.top,left:r.left-i.left}}},offsetParent:function(){return this.map((function(){for(var e=this.offsetParent||l.body;e&&!v.test(e.nodeName)&&"static"==n(e).css("position");)e=e.offsetParent;return e}))}},n.fn.detach=n.fn.remove,["width","height"].forEach((function(e){var t=e.replace(/./,(function(e){return e[0].toUpperCase()}));n.fn[e]=function(r){var i,s=this[0];return void 0===r?L(s)?s["inner"+t]:I(s)?s.documentElement["scroll"+t]:(i=this.offset())&&i[e]:this.each((function(t){(s=n(this)).css(e,K(this,r,t,s[e]()))}))}})),["after","prepend","before","append"].forEach((function(t,r){var i=r%2;n.fn[t]=function(){var t,s,o=n.map(arguments,(function(e){var r=[];return"array"==(t=R(e))?(e.forEach((function(e){return void 0!==e.nodeType?r.push(e):n.zepto.isZ(e)?r=r.concat(e.get()):void(r=r.concat(N.fragment(e)))})),r):"object"==t||null==e?e:N.fragment(e)})),a=this.length>1;return o.length<1?this:this.each((function(t,c){s=i?c:c.parentNode,c=0==r?c.nextSibling:1==r?c.firstChild:2==r?c:null;var u=n.contains(l.documentElement,s);o.forEach((function(t){if(a)t=t.cloneNode(!0);else if(!s)return n(t).remove();s.insertBefore(t,c),u&&G(t,(function(t){if(!(null==t.nodeName||"SCRIPT"!==t.nodeName.toUpperCase()||t.type&&"text/javascript"!==t.type||t.src)){var n=t.ownerDocument?t.ownerDocument.defaultView:e;n.eval.call(n,t.innerHTML)}}))}))}))},n.fn[i?t+"To":"insert"+(r?"Before":"After")]=function(e){return n(e)[t](this),this}})),N.Z.prototype=F.prototype=n.fn,N.uniq=s,N.deserializeValue=W,n.zepto=N,n}();return function(t){var n=1,r=Array.prototype.slice,i=t.isFunction,s=function(e){return"string"==typeof e},o={},a={},c="onfocusin"in e,u={focus:"focusin",blur:"focusout"},l={mouseenter:"mouseover",mouseleave:"mouseout"};function h(e){return e._zid||(e._zid=n++)}function d(e,t,n,r){if((t=f(t)).ns)var i=(s=t.ns,new RegExp("(?:^| )"+s.replace(" "," .* ?")+"(?: |$)"));var s;return(o[h(e)]||[]).filter((function(e){return e&&(!t.e||e.e==t.e)&&(!t.ns||i.test(e.ns))&&(!n||h(e.fn)===h(n))&&(!r||e.sel==r)}))}function f(e){var t=(""+e).split(".");return{e:t[0],ns:t.slice(1).sort().join(" ")}}function p(e,t){return e.del&&!c&&e.e in u||!!t}function g(e){return l[e]||c&&u[e]||e}function m(e,n,r,i,s,a,c){var u=h(e),d=o[u]||(o[u]=[]);n.split(/\s/).forEach((function(n){if("ready"==n)return t(document).ready(r);var o=f(n);o.fn=r,o.sel=s,o.e in l&&(r=function(e){var n=e.relatedTarget;if(!n||n!==this&&!t.contains(this,n))return o.fn.apply(this,arguments)}),o.del=a;var u=a||r;o.proxy=function(t){if(!(t=E(t)).isImmediatePropagationStopped()){try{var n=Object.getOwnPropertyDescriptor(t,"data");n&&!n.writable||(t.data=i)}catch(t){}var r=u.apply(e,null==t._args?[t]:[t].concat(t._args));return!1===r&&(t.preventDefault(),t.stopPropagation()),r}},o.i=d.length,d.push(o),"addEventListener"in e&&e.addEventListener(g(o.e),o.proxy,p(o,c))}))}function v(e,t,n,r,i){var s=h(e);(t||"").split(/\s/).forEach((function(t){d(e,t,n,r).forEach((function(t){delete o[s][t.i],"removeEventListener"in e&&e.removeEventListener(g(t.e),t.proxy,p(t,i))}))}))}a.click=a.mousedown=a.mouseup=a.mousemove="MouseEvents",t.event={add:m,remove:v},t.proxy=function(e,n){var o=2 in arguments&&r.call(arguments,2);if(i(e)){var a=function(){return e.apply(n,o?o.concat(r.call(arguments)):arguments)};return a._zid=h(e),a}if(s(n))return o?(o.unshift(e[n],e),t.proxy.apply(null,o)):t.proxy(e[n],e);throw new TypeError("expected function")},t.fn.bind=function(e,t,n){return this.on(e,t,n)},t.fn.unbind=function(e,t){return this.off(e,t)},t.fn.one=function(e,t,n,r){return this.on(e,t,n,r,1)};var y=function(){return!0},b=function(){return!1},w=/^([A-Z]|returnValue$|layer[XY]$|webkitMovement[XY]$)/,_={preventDefault:"isDefaultPrevented",stopImmediatePropagation:"isImmediatePropagationStopped",stopPropagation:"isPropagationStopped"};function E(e,n){return!n&&e.isDefaultPrevented||(n||(n=e),t.each(_,(function(t,r){var i=n[t];e[t]=function(){return this[r]=y,i&&i.apply(n,arguments)},e[r]=b})),e.timeStamp||(e.timeStamp=Date.now()),(void 0!==n.defaultPrevented?n.defaultPrevented:"returnValue"in n?!1===n.returnValue:n.getPreventDefault&&n.getPreventDefault())&&(e.isDefaultPrevented=y)),e}function x(e){var t,n={originalEvent:e};for(t in e)w.test(t)||void 0===e[t]||(n[t]=e[t]);return E(n,e)}t.fn.delegate=function(e,t,n){return this.on(t,e,n)},t.fn.undelegate=function(e,t,n){return this.off(t,e,n)},t.fn.live=function(e,n){return t(document.body).delegate(this.selector,e,n),this},t.fn.die=function(e,n){return t(document.body).undelegate(this.selector,e,n),this},t.fn.on=function(e,n,o,a,c){var u,l,h=this;return e&&!s(e)?(t.each(e,(function(e,t){h.on(e,n,o,t,c)})),h):(s(n)||i(a)||!1===a||(a=o,o=n,n=void 0),void 0!==a&&!1!==o||(a=o,o=void 0),!1===a&&(a=b),h.each((function(i,s){c&&(u=function(e){return v(s,e.type,a),a.apply(this,arguments)}),n&&(l=function(e){var i,o=t(e.target).closest(n,s).get(0);if(o&&o!==s)return i=t.extend(x(e),{currentTarget:o,liveFired:s}),(u||a).apply(o,[i].concat(r.call(arguments,1)))}),m(s,e,a,o,n,l||u)})))},t.fn.off=function(e,n,r){var o=this;return e&&!s(e)?(t.each(e,(function(e,t){o.off(e,n,t)})),o):(s(n)||i(r)||!1===r||(r=n,n=void 0),!1===r&&(r=b),o.each((function(){v(this,e,r,n)})))},t.fn.trigger=function(e,n){return(e=s(e)||t.isPlainObject(e)?t.Event(e):E(e))._args=n,this.each((function(){e.type in u&&"function"==typeof this[e.type]?this[e.type]():"dispatchEvent"in this?this.dispatchEvent(e):t(this).triggerHandler(e,n)}))},t.fn.triggerHandler=function(e,n){var r,i;return this.each((function(o,a){(r=x(s(e)?t.Event(e):e))._args=n,r.target=a,t.each(d(a,e.type||e),(function(e,t){if(i=t.proxy(r),r.isImmediatePropagationStopped())return!1}))})),i},"focusin focusout focus blur load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select keydown keypress keyup error".split(" ").forEach((function(e){t.fn[e]=function(t){return 0 in arguments?this.bind(e,t):this.trigger(e)}})),t.Event=function(e,t){s(e)||(e=(t=e).type);var n=document.createEvent(a[e]||"Events"),r=!0;if(t)for(var i in t)"bubbles"==i?r=!!t[i]:n[i]=t[i];return n.initEvent(e,r,!0),E(n)}}(r),n=[],r.fn.remove=function(){return this.each((function(){this.parentNode&&("IMG"===this.tagName&&(n.push(this),this.src="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=",t&&clearTimeout(t),t=setTimeout((function(){n=[]}),6e4)),this.parentNode.removeChild(this))}))},function(e){var t={},n=e.fn.data,r=e.camelCase,i=e.expando="Zepto"+ +new Date,s=[];function o(n,o,a){var c=n[i]||(n[i]=++e.uuid),u=t[c]||(t[c]=function(t){var n={};return e.each(t.attributes||s,(function(t,i){0==i.name.indexOf("data-")&&(n[r(i.name.replace("data-",""))]=e.zepto.deserializeValue(i.value))})),n}(n));return void 0!==o&&(u[r(o)]=a),u}e.fn.data=function(s,a){return void 0===a?e.isPlainObject(s)?this.each((function(t,n){e.each(s,(function(e,t){o(n,e,t)}))})):0 in this?function(s,a){var c=s[i],u=c&&t[c];if(void 0===a)return u||o(s);if(u){if(a in u)return u[a];var l=r(a);if(l in u)return u[l]}return n.call(e(s),a)}(this[0],s):void 0:this.each((function(){o(this,s,a)}))},e.data=function(t,n,r){return e(t).data(n,r)},e.hasData=function(n){var r=n[i],s=r&&t[r];return!!s&&!e.isEmptyObject(s)},e.fn.removeData=function(n){return"string"==typeof n&&(n=n.split(/\s+/)),this.each((function(){var s=this[i],o=s&&t[s];o&&e.each(n||o,(function(e){delete o[n?r(this):e]}))}))},["remove","empty"].forEach((function(t){var n=e.fn[t];e.fn[t]=function(){var e=this.find("*");return"remove"===t&&(e=e.add(this)),e.removeData(),n.call(this)}}))}(r),r}(n)},function(e,t,n){"use strict";var r=n(0),i=n(1);function s(e){e&&e.el||r.error("EventBus initialized without el"),this.$el=i.element(e.el)}r.mixin(s.prototype,{trigger:function(e){var t=[].slice.call(arguments,1),n=r.Event("autocomplete:"+e);return this.$el.trigger(n,t),n}}),e.exports=s},function(e,t,n){"use strict";e.exports={wrapper:'<span class="%ROOT%"></span>',dropdown:'<span class="%PREFIX%%DROPDOWN_MENU%"></span>',dataset:'<div class="%PREFIX%%DATASET%-%CLASS%"></div>',suggestions:'<span class="%PREFIX%%SUGGESTIONS%"></span>',suggestion:'<div class="%PREFIX%%SUGGESTION%"></div>'}},function(e,t){e.exports="0.32.0"},function(e,t,n){"use strict";e.exports=function(e){var t=e.match(/Algolia for vanilla JavaScript (\d+\.)(\d+\.)(\d+)/);if(t)return[t[1],t[2],t[3]]}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(15),s=(r=i)&&r.__esModule?r:{default:r};t.default=s.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="2.6.1"},function(e,t,n){"use strict";var r,i=n(23),s=(r=i)&&r.__esModule?r:{default:r};e.exports=s.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=o(n(24)),i=o(n(25)),s=o(n(21));function o(e){return e&&e.__esModule?e:{default:e}}var a=(0,r.default)(i.default);a.version=s.default,t.default=a},function(e,t,n){"use strict";var r=Function.prototype.bind;e.exports=function(e){var t=function(){for(var t=arguments.length,n=Array(t),i=0;i<t;i++)n[i]=arguments[i];return new(r.apply(e,[null].concat(n)))};return t.__proto__=e,t.prototype=e.prototype,t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=d(n(26)),o=d(n(29)),a=d(n(49)),c=d(n(64)),u=d(n(65)),l=d(n(21)),h=d(n(20));function d(e){return e&&e.__esModule?e:{default:e}}var f=function(){function e(t){var n=t.apiKey,i=t.indexName,s=t.inputSelector,u=t.appId,d=void 0===u?"BH4D9OD16A":u,f=t.debug,p=void 0!==f&&f,g=t.algoliaOptions,m=void 0===g?{}:g,v=t.autocompleteOptions,y=void 0===v?{debug:!1,hint:!1,autoselect:!0}:v,b=t.transformData,w=void 0!==b&&b,_=t.queryHook,E=void 0!==_&&_,x=t.handleSelected,S=void 0!==x&&x,C=t.enhancedSearchInput,A=void 0!==C&&C,N=t.layout,O=void 0===N?"collumns":N;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),e.checkArguments({apiKey:n,indexName:i,inputSelector:s,debug:p,algoliaOptions:m,autocompleteOptions:y,transformData:w,queryHook:E,handleSelected:S,enhancedSearchInput:A,layout:O}),this.apiKey=n,this.appId=d,this.indexName=i,this.input=e.getInputFromSelector(s),this.algoliaOptions=r({hitsPerPage:5},m);var T=!(!y||!y.debug)&&y.debug;y.debug=p||T,this.autocompleteOptions=y,this.autocompleteOptions.cssClasses=this.autocompleteOptions.cssClasses||{},this.autocompleteOptions.cssClasses.prefix=this.autocompleteOptions.cssClasses.prefix||"ds",S=S||this.handleSelected,this.isSimpleLayout="simple"===O,this.client=(0,o.default)(this.appId,this.apiKey),this.client.addAlgoliaAgent("docsearch.js "+l.default),A&&(this.input=e.injectSearchBox(this.input)),this.autocomplete=(0,a.default)(this.input,y,[{source:this.getAutocompleteSource(w,E),templates:{suggestion:e.getSuggestionTemplate(this.isSimpleLayout),footer:c.default.footer,empty:e.getEmptyTemplate()}}]),S&&(0,h.default)(".algolia-autocomplete").on("click",".ds-suggestions a",(function(e){e.preventDefault()})),this.autocomplete.on("autocomplete:selected",S.bind(null,this.autocomplete.autocomplete)),this.autocomplete.on("autocomplete:shown",this.handleShown.bind(null,this.input)),A&&e.bindSearchBoxEvent()}return i(e,[{key:"getAutocompleteSource",value:function(t,n){var r=this;return function(i,s){n&&(i=n(i)||i),r.client.search([{indexName:r.indexName,query:i,params:r.algoliaOptions}]).then((function(n){var r=n.results[0].hits;t&&(r=t(r)||r),s(e.formatHits(r))}))}}},{key:"handleSelected",value:function(e,t,n){e.setVal(""),window.location.assign(n.url)}},{key:"handleShown",value:function(e){var t=e.offset().left+e.width()/2,n=(0,h.default)(document).width()/2;isNaN(n)&&(n=900);var r=t-n>=0?"algolia-autocomplete-right":"algolia-autocomplete-left",i=t-n<0?"algolia-autocomplete-right":"algolia-autocomplete-left",s=(0,h.default)(".algolia-autocomplete");s.hasClass(r)||s.addClass(r),s.hasClass(i)&&s.removeClass(i)}}],[{key:"checkArguments",value:function(t){if(!t.apiKey||!t.indexName)throw new Error("Usage:\n documentationSearch({\n apiKey,\n indexName,\n inputSelector,\n [ appId ],\n [ algoliaOptions.{hitsPerPage} ]\n [ autocompleteOptions.{hint,debug} ]\n})");if("string"!=typeof t.inputSelector)throw new Error("Error: inputSelector:"+t.inputSelector+" must be a string. Each selector must match only one element and separated by ','");if(!e.getInputFromSelector(t.inputSelector))throw new Error("Error: No input element in the page matches "+t.inputSelector)}},{key:"injectSearchBox",value:function(e){e.before(c.default.searchBox);var t=e.prev().prev().find("input");return e.remove(),t}},{key:"bindSearchBoxEvent",value:function(){(0,h.default)('.searchbox [type="reset"]').on("click",(function(){(0,h.default)("input#docsearch").focus(),(0,h.default)(this).addClass("hide"),a.default.autocomplete.setVal("")})),(0,h.default)("input#docsearch").on("keyup",(function(){var e=document.querySelector("input#docsearch"),t=document.querySelector('.searchbox [type="reset"]');t.className="searchbox__reset",0===e.value.length&&(t.className+=" hide")}))}},{key:"getInputFromSelector",value:function(e){var t=(0,h.default)(e).filter("input");return t.length?(0,h.default)(t[0]):null}},{key:"formatHits",value:function(t){var n=u.default.deepClone(t).map((function(e){return e._highlightResult&&(e._highlightResult=u.default.mergeKeyWithParent(e._highlightResult,"hierarchy")),u.default.mergeKeyWithParent(e,"hierarchy")})),r=u.default.groupBy(n,"lvl0");return h.default.each(r,(function(e,t){var n=u.default.groupBy(t,"lvl1"),i=u.default.flattenAndFlagFirst(n,"isSubCategoryHeader");r[e]=i})),(r=u.default.flattenAndFlagFirst(r,"isCategoryHeader")).map((function(t){var n=e.formatURL(t),r=u.default.getHighlightedValue(t,"lvl0"),i=u.default.getHighlightedValue(t,"lvl1")||r,s=u.default.compact([u.default.getHighlightedValue(t,"lvl2")||i,u.default.getHighlightedValue(t,"lvl3"),u.default.getHighlightedValue(t,"lvl4"),u.default.getHighlightedValue(t,"lvl5"),u.default.getHighlightedValue(t,"lvl6")]).join('<span class="aa-suggestion-title-separator" aria-hidden="true"> › </span>'),o=u.default.getSnippetedValue(t,"content"),a=i&&""!==i||s&&""!==s,c=s&&""!==s&&s!==i,l=!c&&i&&""!==i&&i!==r;return{isLvl0:!l&&!c,isLvl1:l,isLvl2:c,isLvl1EmptyOrDuplicate:!i||""===i||i===r,isCategoryHeader:t.isCategoryHeader,isSubCategoryHeader:t.isSubCategoryHeader,isTextOrSubcategoryNonEmpty:a,category:r,subcategory:i,title:s,text:o,url:n}}))}},{key:"formatURL",value:function(e){var t=e.url,n=e.anchor;return t?-1!==t.indexOf("#")?t:n?e.url+"#"+e.anchor:t:n?"#"+e.anchor:(console.warn("no anchor nor url for : ",JSON.stringify(e)),null)}},{key:"getEmptyTemplate",value:function(){return function(e){return s.default.compile(c.default.empty).render(e)}}},{key:"getSuggestionTemplate",value:function(e){var t=e?c.default.suggestionSimple:c.default.suggestion,n=s.default.compile(t);return function(e){return n.render(e)}}}]),e}();t.default=f},function(e,t,n){var r=n(27);r.Template=n(28).Template,r.template=r.Template,e.exports=r},function(e,t,n){!function(e){var t=/\S/,n=/\"/g,r=/\n/g,i=/\r/g,s=/\\/g,o=/\u2028/,a=/\u2029/;function c(e){return e.trim?e.trim():e.replace(/^\s*|\s*$/g,"")}function u(e,t,n){if(t.charAt(n)!=e.charAt(0))return!1;for(var r=1,i=e.length;r<i;r++)if(t.charAt(n+r)!=e.charAt(r))return!1;return!0}e.tags={"#":1,"^":2,"<":3,$:4,"/":5,"!":6,">":7,"=":8,_v:9,"{":10,"&":11,_t:12},e.scan=function(n,r){var i,s=n.length,o=0,a=null,l=null,h="",d=[],f=!1,p=0,g=0,m="{{",v="}}";function y(){h.length>0&&(d.push({tag:"_t",text:new String(h)}),h="")}function b(n,r){if(y(),n&&function(){for(var n=!0,r=g;r<d.length;r++)if(!(n=e.tags[d[r].tag]<e.tags._v||"_t"==d[r].tag&&null===d[r].text.match(t)))return!1;return n}())for(var i,s=g;s<d.length;s++)d[s].text&&((i=d[s+1])&&">"==i.tag&&(i.indent=d[s].text.toString()),d.splice(s,1));else r||d.push({tag:"\n"});f=!1,g=d.length}function w(e,t){var n="="+v,r=e.indexOf(n,t),i=c(e.substring(e.indexOf("=",t)+1,r)).split(" ");return m=i[0],v=i[i.length-1],r+n.length-1}for(r&&(r=r.split(" "),m=r[0],v=r[1]),p=0;p<s;p++)0==o?u(m,n,p)?(--p,y(),o=1):"\n"==n.charAt(p)?b(f):h+=n.charAt(p):1==o?(p+=m.length-1,"="==(a=(l=e.tags[n.charAt(p+1)])?n.charAt(p+1):"_v")?(p=w(n,p),o=0):(l&&p++,o=2),f=p):u(v,n,p)?(d.push({tag:a,n:c(h),otag:m,ctag:v,i:"/"==a?f-m.length:p+v.length}),h="",p+=v.length-1,o=0,"{"==a&&("}}"==v?p++:"}"===(i=d[d.length-1]).n.substr(i.n.length-1)&&(i.n=i.n.substring(0,i.n.length-1)))):h+=n.charAt(p);return b(f,!0),d};var l={_t:!0,"\n":!0,$:!0,"/":!0};function h(e,t){for(var n=0,r=t.length;n<r;n++)if(t[n].o==e.n)return e.tag="#",!0}function d(e,t,n){for(var r=0,i=n.length;r<i;r++)if(n[r].c==e&&n[r].o==t)return!0}function f(e){var t=[];for(var n in e.partials)t.push('"'+g(n)+'":{name:"'+g(e.partials[n].name)+'", '+f(e.partials[n])+"}");return"partials: {"+t.join(",")+"}, subs: "+function(e){var t=[];for(var n in e)t.push('"'+g(n)+'": function(c,p,t,i) {'+e[n]+"}");return"{ "+t.join(",")+" }"}(e.subs)}e.stringify=function(t,n,r){return"{code: function (c,p,i) { "+e.wrapMain(t.code)+" },"+f(t)+"}"};var p=0;function g(e){return e.replace(s,"\\\\").replace(n,'\\"').replace(r,"\\n").replace(i,"\\r").replace(o,"\\u2028").replace(a,"\\u2029")}function m(e){return~e.indexOf(".")?"d":"f"}function v(e,t){var n="<"+(t.prefix||"")+e.n+p++;return t.partials[n]={name:e.n,partials:{}},t.code+='t.b(t.rp("'+g(n)+'",c,p,"'+(e.indent||"")+'"));',n}function y(e,t){t.code+="t.b(t.t(t."+m(e.n)+'("'+g(e.n)+'",c,p,0)));'}function b(e){return"t.b("+e+");"}e.generate=function(t,n,r){p=0;var i={code:"",subs:{},partials:{}};return e.walk(t,i),r.asString?this.stringify(i,n,r):this.makeTemplate(i,n,r)},e.wrapMain=function(e){return'var t=this;t.b(i=i||"");'+e+"return t.fl();"},e.template=e.Template,e.makeTemplate=function(e,t,n){var r=this.makePartials(e);return r.code=new Function("c","p","i",this.wrapMain(e.code)),new this.template(r,t,this,n)},e.makePartials=function(e){var t,n={subs:{},partials:e.partials,name:e.name};for(t in n.partials)n.partials[t]=this.makePartials(n.partials[t]);for(t in e.subs)n.subs[t]=new Function("c","p","t","i",e.subs[t]);return n},e.codegen={"#":function(t,n){n.code+="if(t.s(t."+m(t.n)+'("'+g(t.n)+'",c,p,1),c,p,0,'+t.i+","+t.end+',"'+t.otag+" "+t.ctag+'")){t.rs(c,p,function(c,p,t){',e.walk(t.nodes,n),n.code+="});c.pop();}"},"^":function(t,n){n.code+="if(!t.s(t."+m(t.n)+'("'+g(t.n)+'",c,p,1),c,p,1,0,0,"")){',e.walk(t.nodes,n),n.code+="};"},">":v,"<":function(t,n){var r={partials:{},code:"",subs:{},inPartial:!0};e.walk(t.nodes,r);var i=n.partials[v(t,n)];i.subs=r.subs,i.partials=r.partials},$:function(t,n){var r={subs:{},code:"",partials:n.partials,prefix:t.n};e.walk(t.nodes,r),n.subs[t.n]=r.code,n.inPartial||(n.code+='t.sub("'+g(t.n)+'",c,p,i);')},"\n":function(e,t){t.code+=b('"\\n"'+(e.last?"":" + i"))},_v:function(e,t){t.code+="t.b(t.v(t."+m(e.n)+'("'+g(e.n)+'",c,p,0)));'},_t:function(e,t){t.code+=b('"'+g(e.text)+'"')},"{":y,"&":y},e.walk=function(t,n){for(var r,i=0,s=t.length;i<s;i++)(r=e.codegen[t[i].tag])&&r(t[i],n);return n},e.parse=function(t,n,r){return function t(n,r,i,s){var o,a=[],c=null,u=null;for(o=i[i.length-1];n.length>0;){if(u=n.shift(),o&&"<"==o.tag&&!(u.tag in l))throw new Error("Illegal content in < super tag.");if(e.tags[u.tag]<=e.tags.$||h(u,s))i.push(u),u.nodes=t(n,u.tag,i,s);else{if("/"==u.tag){if(0===i.length)throw new Error("Closing tag without opener: /"+u.n);if(c=i.pop(),u.n!=c.n&&!d(u.n,c.n,s))throw new Error("Nesting error: "+c.n+" vs. "+u.n);return c.end=u.i,a}"\n"==u.tag&&(u.last=0==n.length||"\n"==n[0].tag)}a.push(u)}if(i.length>0)throw new Error("missing closing tag: "+i.pop().n);return a}(t,0,[],(r=r||{}).sectionTags||[])},e.cache={},e.cacheKey=function(e,t){return[e,!!t.asString,!!t.disableLambda,t.delimiters,!!t.modelGet].join("||")},e.compile=function(t,n){n=n||{};var r=e.cacheKey(t,n),i=this.cache[r];if(i){var s=i.partials;for(var o in s)delete s[o].instance;return i}return i=this.generate(this.parse(this.scan(t,n.delimiters),t,n),t,n),this.cache[r]=i}}(t)},function(e,t,n){!function(e){function t(e,t,n){var r;return t&&"object"==typeof t&&(void 0!==t[e]?r=t[e]:n&&t.get&&"function"==typeof t.get&&(r=t.get(e))),r}e.Template=function(e,t,n,r){e=e||{},this.r=e.code||this.r,this.c=n,this.options=r||{},this.text=t||"",this.partials=e.partials||{},this.subs=e.subs||{},this.buf=""},e.Template.prototype={r:function(e,t,n){return""},v:function(e){return e=c(e),a.test(e)?e.replace(n,"&amp;").replace(r,"&lt;").replace(i,"&gt;").replace(s,"&#39;").replace(o,"&quot;"):e},t:c,render:function(e,t,n){return this.ri([e],t||{},n)},ri:function(e,t,n){return this.r(e,t,n)},ep:function(e,t){var n=this.partials[e],r=t[n.name];if(n.instance&&n.base==r)return n.instance;if("string"==typeof r){if(!this.c)throw new Error("No compiler available.");r=this.c.compile(r,this.options)}if(!r)return null;if(this.partials[e].base=r,n.subs){for(key in t.stackText||(t.stackText={}),n.subs)t.stackText[key]||(t.stackText[key]=void 0!==this.activeSub&&t.stackText[this.activeSub]?t.stackText[this.activeSub]:this.text);r=function(e,t,n,r,i,s){function o(){}function a(){}var c;o.prototype=e,a.prototype=e.subs;var u=new o;for(c in u.subs=new a,u.subsText={},u.buf="",r=r||{},u.stackSubs=r,u.subsText=s,t)r[c]||(r[c]=t[c]);for(c in r)u.subs[c]=r[c];for(c in i=i||{},u.stackPartials=i,n)i[c]||(i[c]=n[c]);for(c in i)u.partials[c]=i[c];return u}(r,n.subs,n.partials,this.stackSubs,this.stackPartials,t.stackText)}return this.partials[e].instance=r,r},rp:function(e,t,n,r){var i=this.ep(e,n);return i?i.ri(t,n,r):""},rs:function(e,t,n){var r=e[e.length-1];if(u(r))for(var i=0;i<r.length;i++)e.push(r[i]),n(e,t,this),e.pop();else n(e,t,this)},s:function(e,t,n,r,i,s,o){var a;return(!u(e)||0!==e.length)&&("function"==typeof e&&(e=this.ms(e,t,n,r,i,s,o)),a=!!e,!r&&a&&t&&t.push("object"==typeof e?e:t[t.length-1]),a)},d:function(e,n,r,i){var s,o=e.split("."),a=this.f(o[0],n,r,i),c=this.options.modelGet,l=null;if("."===e&&u(n[n.length-2]))a=n[n.length-1];else for(var h=1;h<o.length;h++)void 0!==(s=t(o[h],a,c))?(l=a,a=s):a="";return!(i&&!a)&&(i||"function"!=typeof a||(n.push(l),a=this.mv(a,n,r),n.pop()),a)},f:function(e,n,r,i){for(var s=!1,o=!1,a=this.options.modelGet,c=n.length-1;c>=0;c--)if(void 0!==(s=t(e,n[c],a))){o=!0;break}return o?(i||"function"!=typeof s||(s=this.mv(s,n,r)),s):!i&&""},ls:function(e,t,n,r,i){var s=this.options.delimiters;return this.options.delimiters=i,this.b(this.ct(c(e.call(t,r)),t,n)),this.options.delimiters=s,!1},ct:function(e,t,n){if(this.options.disableLambda)throw new Error("Lambda features disabled.");return this.c.compile(e,this.options).render(t,n)},b:function(e){this.buf+=e},fl:function(){var e=this.buf;return this.buf="",e},ms:function(e,t,n,r,i,s,o){var a,c=t[t.length-1],u=e.call(c);return"function"==typeof u?!!r||(a=this.activeSub&&this.subsText&&this.subsText[this.activeSub]?this.subsText[this.activeSub]:this.text,this.ls(u,c,n,a.substring(i,s),o)):u},mv:function(e,t,n){var r=t[t.length-1],i=e.call(r);return"function"==typeof i?this.ct(c(i.call(r)),r,n):i},sub:function(e,t,n,r){var i=this.subs[e];i&&(this.activeSub=e,i(t,n,this,r),this.activeSub=!1)}};var n=/&/g,r=/</g,i=/>/g,s=/\'/g,o=/\"/g,a=/[&<>\"\']/;function c(e){return String(null==e?"":e)}var u=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}}(t)},function(e,t,n){"use strict";var r=n(30),i=n(41);e.exports=i(r,"(lite) ")},function(e,t,n){e.exports=c;var r=n(5),i=n(31),s=n(32),o=n(38),a=Object({NODE_ENV:"production"}).RESET_APP_DATA_TIMER&&parseInt(Object({NODE_ENV:"production"}).RESET_APP_DATA_TIMER,10)||12e4;function c(e,t,i){var s=n(8)("algoliasearch"),o=n(3),a=n(6),c=n(7),l="Usage: algoliasearch(applicationID, apiKey, opts)";if(!0!==i._allowEmptyCredentials&&!e)throw new r.AlgoliaSearchError("Please provide an application ID. "+l);if(!0!==i._allowEmptyCredentials&&!t)throw new r.AlgoliaSearchError("Please provide an API key. "+l);this.applicationID=e,this.apiKey=t,this.hosts={read:[],write:[]},i=i||{},this._timeouts=i.timeouts||{connect:1e3,read:2e3,write:3e4},i.timeout&&(this._timeouts.connect=this._timeouts.read=this._timeouts.write=i.timeout);var h=i.protocol||"https:";if(/:$/.test(h)||(h+=":"),"http:"!==h&&"https:"!==h)throw new r.AlgoliaSearchError("protocol must be `http:` or `https:` (was `"+i.protocol+"`)");if(this._checkAppIdData(),i.hosts)a(i.hosts)?(this.hosts.read=o(i.hosts),this.hosts.write=o(i.hosts)):(this.hosts.read=o(i.hosts.read),this.hosts.write=o(i.hosts.write));else{var d=c(this._shuffleResult,(function(t){return e+"-"+t+".algolianet.com"})),f=(!1===i.dsn?"":"-dsn")+".algolia.net";this.hosts.read=[this.applicationID+f].concat(d),this.hosts.write=[this.applicationID+".algolia.net"].concat(d)}this.hosts.read=c(this.hosts.read,u(h)),this.hosts.write=c(this.hosts.write,u(h)),this.extraHeaders={},this.cache=i._cache||{},this._ua=i._ua,this._useCache=!(void 0!==i._useCache&&!i._cache)||i._useCache,this._useRequestCache=this._useCache&&i._useRequestCache,this._useFallback=void 0===i.useFallback||i.useFallback,this._setTimeout=i._setTimeout,s("init done, %j",this)}function u(e){return function(t){return e+"//"+t.toLowerCase()}}function l(e){if(void 0===Array.prototype.toJSON)return JSON.stringify(e);var t=Array.prototype.toJSON;delete Array.prototype.toJSON;var n=JSON.stringify(e);return Array.prototype.toJSON=t,n}function h(e){var t={};for(var n in e){var r;Object.prototype.hasOwnProperty.call(e,n)&&(r="x-algolia-api-key"===n||"x-algolia-application-id"===n?"**hidden for security purposes**":e[n],t[n]=r)}return t}c.prototype.initIndex=function(e){return new s(this,e)},c.prototype.setExtraHeader=function(e,t){this.extraHeaders[e.toLowerCase()]=t},c.prototype.getExtraHeader=function(e){return this.extraHeaders[e.toLowerCase()]},c.prototype.unsetExtraHeader=function(e){delete this.extraHeaders[e.toLowerCase()]},c.prototype.addAlgoliaAgent=function(e){-1===this._ua.indexOf(";"+e)&&(this._ua+=";"+e)},c.prototype._jsonRequest=function(e){this._checkAppIdData();var t,s,o,a=n(8)("algoliasearch:"+e.url),c=e.additionalUA||"",u=e.cache,d=this,f=0,p=!1,g=d._useFallback&&d._request.fallback&&e.fallback;this.apiKey.length>500&&void 0!==e.body&&(void 0!==e.body.params||void 0!==e.body.requests)?(e.body.apiKey=this.apiKey,o=this._computeRequestHeaders({additionalUA:c,withApiKey:!1,headers:e.headers})):o=this._computeRequestHeaders({additionalUA:c,headers:e.headers}),void 0!==e.body&&(t=l(e.body)),a("request start");var m=[];function v(e,t,n){return d._useCache&&e&&t&&void 0!==t[n]}function y(t,n){if(v(d._useRequestCache,u,s)&&t.catch((function(){delete u[s]})),"function"!=typeof e.callback)return t.then(n);t.then((function(t){i((function(){e.callback(null,n(t))}),d._setTimeout||setTimeout)}),(function(t){i((function(){e.callback(t)}),d._setTimeout||setTimeout)}))}if(d._useCache&&d._useRequestCache&&(s=e.url),d._useCache&&d._useRequestCache&&t&&(s+="_body_"+t),v(d._useRequestCache,u,s)){a("serving request from cache");var b=u[s];return y("function"!=typeof b.then?d._promise.resolve({responseText:b}):b,(function(e){return JSON.parse(e.responseText)}))}var w=function n(i,y){d._checkAppIdData();var b=new Date;if(d._useCache&&!d._useRequestCache&&(s=e.url),d._useCache&&!d._useRequestCache&&t&&(s+="_body_"+y.body),v(!d._useRequestCache,u,s)){a("serving response from cache");var w=u[s];return d._promise.resolve({body:JSON.parse(w),responseText:w})}if(f>=d.hosts[e.hostType].length)return!g||p?(a("could not get any response"),d._promise.reject(new r.AlgoliaSearchError("Cannot connect to the AlgoliaSearch API. Send an email to [email protected] to report and resolve the issue. Application id was: "+d.applicationID,{debugData:m}))):(a("switching to fallback"),f=0,y.method=e.fallback.method,y.url=e.fallback.url,y.jsonBody=e.fallback.body,y.jsonBody&&(y.body=l(y.jsonBody)),o=d._computeRequestHeaders({additionalUA:c,headers:e.headers}),y.timeouts=d._getTimeoutsForRequest(e.hostType),d._setHostIndexByType(0,e.hostType),p=!0,n(d._request.fallback,y));var _=d._getHostByType(e.hostType),E=_+y.url,x={body:y.body,jsonBody:y.jsonBody,method:y.method,headers:o,timeouts:y.timeouts,debug:a,forceAuthHeaders:y.forceAuthHeaders};return a("method: %s, url: %s, headers: %j, timeouts: %d",x.method,E,x.headers,x.timeouts),i===d._request.fallback&&a("using fallback"),i.call(d,E,x).then((function(e){var n=e&&e.body&&e.body.message&&e.body.status||e.statusCode||e&&e.body&&200;a("received response: statusCode: %s, computed statusCode: %d, headers: %j",e.statusCode,n,e.headers);var i=2===Math.floor(n/100),c=new Date;if(m.push({currentHost:_,headers:h(o),content:t||null,contentLength:void 0!==t?t.length:null,method:y.method,timeouts:y.timeouts,url:y.url,startTime:b,endTime:c,duration:c-b,statusCode:n}),i)return d._useCache&&!d._useRequestCache&&u&&(u[s]=e.responseText),{responseText:e.responseText,body:e.body};if(4!==Math.floor(n/100))return f+=1,S();a("unrecoverable error");var l=new r.AlgoliaSearchError(e.body&&e.body.message,{debugData:m,statusCode:n});return d._promise.reject(l)}),(function(s){a("error: %s, stack: %s",s.message,s.stack);var c=new Date;return m.push({currentHost:_,headers:h(o),content:t||null,contentLength:void 0!==t?t.length:null,method:y.method,timeouts:y.timeouts,url:y.url,startTime:b,endTime:c,duration:c-b}),s instanceof r.AlgoliaSearchError||(s=new r.Unknown(s&&s.message,s)),f+=1,s instanceof r.Unknown||s instanceof r.UnparsableJSON||f>=d.hosts[e.hostType].length&&(p||!g)?(s.debugData=m,d._promise.reject(s)):s instanceof r.RequestTimeout?(a("retrying request with higher timeout"),d._incrementHostIndex(e.hostType),d._incrementTimeoutMultipler(),y.timeouts=d._getTimeoutsForRequest(e.hostType),n(i,y)):S()}));function S(){return a("retrying request"),d._incrementHostIndex(e.hostType),n(i,y)}}(d._request,{url:e.url,method:e.method,body:t,jsonBody:e.body,timeouts:d._getTimeoutsForRequest(e.hostType),forceAuthHeaders:e.forceAuthHeaders});return d._useCache&&d._useRequestCache&&u&&(u[s]=w),y(w,(function(e){return e.body}))},c.prototype._getSearchParams=function(e,t){if(null==e)return t;for(var n in e)null!==n&&void 0!==e[n]&&e.hasOwnProperty(n)&&(t+=""===t?"":"&",t+=n+"="+encodeURIComponent("[object Array]"===Object.prototype.toString.call(e[n])?l(e[n]):e[n]));return t},c.prototype._computeRequestHeaders=function(e){var t=n(2),r={"x-algolia-agent":e.additionalUA?this._ua+";"+e.additionalUA:this._ua,"x-algolia-application-id":this.applicationID};return!1!==e.withApiKey&&(r["x-algolia-api-key"]=this.apiKey),this.userToken&&(r["x-algolia-usertoken"]=this.userToken),this.securityTags&&(r["x-algolia-tagfilters"]=this.securityTags),t(this.extraHeaders,(function(e,t){r[t]=e})),e.headers&&t(e.headers,(function(e,t){r[t]=e})),r},c.prototype.search=function(e,t,r){var i=n(6),s=n(7);if(!i(e))throw new Error("Usage: client.search(arrayOfQueries[, callback])");"function"==typeof t?(r=t,t={}):void 0===t&&(t={});var o=this,a={requests:s(e,(function(e){var t="";return void 0!==e.query&&(t+="query="+encodeURIComponent(e.query)),{indexName:e.indexName,params:o._getSearchParams(e.params,t)}}))},c=s(a.requests,(function(e,t){return t+"="+encodeURIComponent("/1/indexes/"+encodeURIComponent(e.indexName)+"?"+e.params)})).join("&");return void 0!==t.strategy&&(a.strategy=t.strategy),this._jsonRequest({cache:this.cache,method:"POST",url:"/1/indexes/*/queries",body:a,hostType:"read",fallback:{method:"GET",url:"/1/indexes/*",body:{params:c}},callback:r})},c.prototype.searchForFacetValues=function(e){var t=n(6),r=n(7),i="Usage: client.searchForFacetValues([{indexName, params: {facetName, facetQuery, ...params}}, ...queries])";if(!t(e))throw new Error(i);var s=this;return s._promise.all(r(e,(function(e){if(!e||void 0===e.indexName||void 0===e.params.facetName||void 0===e.params.facetQuery)throw new Error(i);var t=n(3),r=n(14),o=e.indexName,a=e.params,c=a.facetName,u=r(t(a),(function(e){return"facetName"===e})),l=s._getSearchParams(u,"");return s._jsonRequest({cache:s.cache,method:"POST",url:"/1/indexes/"+encodeURIComponent(o)+"/facets/"+encodeURIComponent(c)+"/query",hostType:"read",body:{params:l}})})))},c.prototype.setSecurityTags=function(e){if("[object Array]"===Object.prototype.toString.call(e)){for(var t=[],n=0;n<e.length;++n)if("[object Array]"===Object.prototype.toString.call(e[n])){for(var r=[],i=0;i<e[n].length;++i)r.push(e[n][i]);t.push("("+r.join(",")+")")}else t.push(e[n]);e=t.join(",")}this.securityTags=e},c.prototype.setUserToken=function(e){this.userToken=e},c.prototype.clearCache=function(){this.cache={}},c.prototype.setRequestTimeout=function(e){e&&(this._timeouts.connect=this._timeouts.read=this._timeouts.write=e)},c.prototype.setTimeouts=function(e){this._timeouts=e},c.prototype.getTimeouts=function(){return this._timeouts},c.prototype._getAppIdData=function(){var e=o.get(this.applicationID);return null!==e&&this._cacheAppIdData(e),e},c.prototype._setAppIdData=function(e){return e.lastChange=(new Date).getTime(),this._cacheAppIdData(e),o.set(this.applicationID,e)},c.prototype._checkAppIdData=function(){var e=this._getAppIdData(),t=(new Date).getTime();return null===e||t-e.lastChange>a?this._resetInitialAppIdData(e):e},c.prototype._resetInitialAppIdData=function(e){var t=e||{};return t.hostIndexes={read:0,write:0},t.timeoutMultiplier=1,t.shuffleResult=t.shuffleResult||function(e){for(var t,n,r=e.length;0!==r;)n=Math.floor(Math.random()*r),t=e[r-=1],e[r]=e[n],e[n]=t;return e}([1,2,3]),this._setAppIdData(t)},c.prototype._cacheAppIdData=function(e){this._hostIndexes=e.hostIndexes,this._timeoutMultiplier=e.timeoutMultiplier,this._shuffleResult=e.shuffleResult},c.prototype._partialAppIdDataUpdate=function(e){var t=n(2),r=this._getAppIdData();return t(e,(function(e,t){r[t]=e})),this._setAppIdData(r)},c.prototype._getHostByType=function(e){return this.hosts[e][this._getHostIndexByType(e)]},c.prototype._getTimeoutMultiplier=function(){return this._timeoutMultiplier},c.prototype._getHostIndexByType=function(e){return this._hostIndexes[e]},c.prototype._setHostIndexByType=function(e,t){var r=n(3)(this._hostIndexes);return r[t]=e,this._partialAppIdDataUpdate({hostIndexes:r}),e},c.prototype._incrementHostIndex=function(e){return this._setHostIndexByType((this._getHostIndexByType(e)+1)%this.hosts[e].length,e)},c.prototype._incrementTimeoutMultipler=function(){var e=Math.max(this._timeoutMultiplier+1,4);return this._partialAppIdDataUpdate({timeoutMultiplier:e})},c.prototype._getTimeoutsForRequest=function(e){return{connect:this._timeouts.connect*this._timeoutMultiplier,complete:this._timeouts[e]*this._timeoutMultiplier}}},function(e,t){e.exports=function(e,t){t(e,0)}},function(e,t,n){var r=n(13),i=n(33),s=n(34);function o(e,t){this.indexName=t,this.as=e,this.typeAheadArgs=null,this.typeAheadValueOption=null,this.cache={}}e.exports=o,o.prototype.clearCache=function(){this.cache={}},o.prototype.search=r("query"),o.prototype.similarSearch=r("similarQuery"),o.prototype.browse=function(e,t,r){var i,s,o=n(35),a=this;0===arguments.length||1===arguments.length&&"function"==typeof arguments[0]?(i=0,r=arguments[0],e=void 0):"number"==typeof arguments[0]?(i=arguments[0],"number"==typeof arguments[1]?s=arguments[1]:"function"==typeof arguments[1]&&(r=arguments[1],s=void 0),e=void 0,t=void 0):"object"==typeof arguments[0]?("function"==typeof arguments[1]&&(r=arguments[1]),t=arguments[0],e=void 0):"string"==typeof arguments[0]&&"function"==typeof arguments[1]&&(r=arguments[1],t=void 0),t=o({},t||{},{page:i,hitsPerPage:s,query:e});var c=this.as._getSearchParams(t,"");return this.as._jsonRequest({method:"POST",url:"/1/indexes/"+encodeURIComponent(a.indexName)+"/browse",body:{params:c},hostType:"read",callback:r})},o.prototype.browseFrom=function(e,t){return this.as._jsonRequest({method:"POST",url:"/1/indexes/"+encodeURIComponent(this.indexName)+"/browse",body:{cursor:e},hostType:"read",callback:t})},o.prototype.searchForFacetValues=function(e,t){var r=n(3),i=n(14);if(void 0===e.facetName||void 0===e.facetQuery)throw new Error("Usage: index.searchForFacetValues({facetName, facetQuery, ...params}[, callback])");var s=e.facetName,o=i(r(e),(function(e){return"facetName"===e})),a=this.as._getSearchParams(o,"");return this.as._jsonRequest({method:"POST",url:"/1/indexes/"+encodeURIComponent(this.indexName)+"/facets/"+encodeURIComponent(s)+"/query",hostType:"read",body:{params:a},callback:t})},o.prototype.searchFacet=i((function(e,t){return this.searchForFacetValues(e,t)}),s("index.searchFacet(params[, callback])","index.searchForFacetValues(params[, callback])")),o.prototype._search=function(e,t,n,r){return this.as._jsonRequest({cache:this.cache,method:"POST",url:t||"/1/indexes/"+encodeURIComponent(this.indexName)+"/query",body:{params:e},hostType:"read",fallback:{method:"GET",url:"/1/indexes/"+encodeURIComponent(this.indexName),body:{params:e}},callback:n,additionalUA:r})},o.prototype.getObject=function(e,t,n){var r=this;1!==arguments.length&&"function"!=typeof t||(n=t,t=void 0);var i="";if(void 0!==t){i="?attributes=";for(var s=0;s<t.length;++s)0!==s&&(i+=","),i+=t[s]}return this.as._jsonRequest({method:"GET",url:"/1/indexes/"+encodeURIComponent(r.indexName)+"/"+encodeURIComponent(e)+i,hostType:"read",callback:n})},o.prototype.getObjects=function(e,t,r){var i=n(6),s=n(7),o="Usage: index.getObjects(arrayOfObjectIDs[, callback])";if(!i(e))throw new Error(o);var a=this;1!==arguments.length&&"function"!=typeof t||(r=t,t=void 0);var c={requests:s(e,(function(e){var n={indexName:a.indexName,objectID:e};return t&&(n.attributesToRetrieve=t.join(",")),n}))};return this.as._jsonRequest({method:"POST",url:"/1/indexes/*/objects",hostType:"read",body:c,callback:r})},o.prototype.as=null,o.prototype.indexName=null,o.prototype.typeAheadArgs=null,o.prototype.typeAheadValueOption=null},function(e,t){e.exports=function(e,t){var n=!1;return function(){return n||(console.warn(t),n=!0),e.apply(this,arguments)}}},function(e,t){e.exports=function(e,t){var n=e.toLowerCase().replace(/[\.\(\)]/g,"");return"algoliasearch: `"+e+"` was replaced by `"+t+"`. Please see https://github.com/algolia/algoliasearch-client-javascript/wiki/Deprecated#"+n}},function(e,t,n){var r=n(2);e.exports=function e(t){var n=Array.prototype.slice.call(arguments);return r(n,(function(n){for(var r in n)n.hasOwnProperty(r)&&("object"==typeof t[r]&&"object"==typeof n[r]?t[r]=e({},t[r],n[r]):void 0!==n[r]&&(t[r]=n[r]))})),t}},function(e,t,n){"use strict";var r=Object.prototype.hasOwnProperty,i=Object.prototype.toString,s=Array.prototype.slice,o=n(37),a=Object.prototype.propertyIsEnumerable,c=!a.call({toString:null},"toString"),u=a.call((function(){}),"prototype"),l=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],h=function(e){var t=e.constructor;return t&&t.prototype===e},d={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},f=function(){if("undefined"==typeof window)return!1;for(var e in window)try{if(!d["$"+e]&&r.call(window,e)&&null!==window[e]&&"object"==typeof window[e])try{h(window[e])}catch(e){return!0}}catch(e){return!0}return!1}(),p=function(e){var t=null!==e&&"object"==typeof e,n="[object Function]"===i.call(e),s=o(e),a=t&&"[object String]"===i.call(e),d=[];if(!t&&!n&&!s)throw new TypeError("Object.keys called on a non-object");var p=u&&n;if(a&&e.length>0&&!r.call(e,0))for(var g=0;g<e.length;++g)d.push(String(g));if(s&&e.length>0)for(var m=0;m<e.length;++m)d.push(String(m));else for(var v in e)p&&"prototype"===v||!r.call(e,v)||d.push(String(v));if(c)for(var y=function(e){if("undefined"==typeof window||!f)return h(e);try{return h(e)}catch(e){return!1}}(e),b=0;b<l.length;++b)y&&"constructor"===l[b]||!r.call(e,l[b])||d.push(l[b]);return d};p.shim=function(){if(Object.keys){if(!function(){return 2===(Object.keys(arguments)||"").length}(1,2)){var e=Object.keys;Object.keys=function(t){return o(t)?e(s.call(t)):e(t)}}}else Object.keys=p;return Object.keys||p},e.exports=p},function(e,t,n){"use strict";var r=Object.prototype.toString;e.exports=function(e){var t=r.call(e),n="[object Arguments]"===t;return n||(n="[object Array]"!==t&&null!==e&&"object"==typeof e&&"number"==typeof e.length&&e.length>=0&&"[object Function]"===r.call(e.callee)),n}},function(e,t,n){(function(t){var r,i=n(8)("algoliasearch:src/hostIndexState.js"),s={state:{},set:function(e,t){return this.state[e]=t,this.state[e]},get:function(e){return this.state[e]||null}},o={set:function(e,n){s.set(e,n);try{var r=JSON.parse(t.localStorage["algoliasearch-client-js"]);return r[e]=n,t.localStorage["algoliasearch-client-js"]=JSON.stringify(r),r[e]}catch(t){return a(e,t)}},get:function(e){try{return JSON.parse(t.localStorage["algoliasearch-client-js"])[e]||null}catch(t){return a(e,t)}}};function a(e,n){return i("localStorage failed with",n),function(){try{t.localStorage.removeItem("algoliasearch-client-js")}catch(e){}}(),(r=s).get(e)}function c(e,t){return 1===arguments.length?r.get(e):r.set(e,t)}function u(){try{return"localStorage"in t&&null!==t.localStorage&&(t.localStorage["algoliasearch-client-js"]||t.localStorage.setItem("algoliasearch-client-js",JSON.stringify({})),!0)}catch(e){return!1}}r=u()?o:s,e.exports={get:c,set:c,supportsLocalStorage:u}}).call(t,n(4))},function(e,t,n){var r;function i(e){function n(){if(n.enabled){var e=n,i=+new Date,s=i-(r||i);e.diff=s,e.prev=r,e.curr=i,r=i;for(var o=new Array(arguments.length),a=0;a<o.length;a++)o[a]=arguments[a];o[0]=t.coerce(o[0]),"string"!=typeof o[0]&&o.unshift("%O");var c=0;o[0]=o[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;c++;var i=t.formatters[r];if("function"==typeof i){var s=o[c];n=i.call(e,s),o.splice(c,1),c--}return n})),t.formatArgs.call(e,o);var u=n.log||t.log||console.log.bind(console);u.apply(e,o)}}return n.namespace=e,n.enabled=t.enabled(e),n.useColors=t.useColors(),n.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),"function"==typeof t.init&&t.init(n),n}(t=e.exports=i.debug=i.default=i).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){t.save(e),t.names=[],t.skips=[];for(var n=("string"==typeof e?e:"").split(/[\s,]+/),r=n.length,i=0;i<r;i++)n[i]&&("-"===(e=n[i].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(40),t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=6e4,i=36e5,s=24*i;function o(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var a,c=typeof e;if("string"===c&&e.length>0)return function(e){if(!((e=String(e)).length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var o=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*o;case"days":case"day":case"d":return o*s;case"hours":case"hour":case"hrs":case"hr":case"h":return o*i;case"minutes":case"minute":case"mins":case"min":case"m":return o*r;case"seconds":case"second":case"secs":case"sec":case"s":return o*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return o;default:return}}}}(e);if("number"===c&&!1===isNaN(e))return t.long?o(a=e,s,"day")||o(a,i,"hour")||o(a,r,"minute")||o(a,n,"second")||a+" ms":function(e){return e>=s?Math.round(e/s)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){"use strict";var r=n(42),i=r.Promise||n(43).Promise;e.exports=function(e,t){var s=n(12),o=n(5),a=n(44),c=n(46),u=n(47);function l(e,t,r){return(r=n(3)(r||{}))._ua=r._ua||l.ua,new d(e,t,r)}t=t||"",l.version=n(48),l.ua="Algolia for vanilla JavaScript "+t+l.version,l.initPlaces=u(l),r.__algolia={debug:n(8),algoliasearch:l};var h={hasXMLHttpRequest:"XMLHttpRequest"in r,hasXDomainRequest:"XDomainRequest"in r};function d(){e.apply(this,arguments)}return h.hasXMLHttpRequest&&(h.cors="withCredentials"in new XMLHttpRequest),s(d,e),d.prototype._request=function(e,t){return new i((function(n,r){if(h.cors||h.hasXDomainRequest){e=a(e,t.headers);var i,s,c=t.body,u=h.cors?new XMLHttpRequest:new XDomainRequest,l=!1;i=setTimeout(d,t.timeouts.connect),u.onprogress=function(){l||f()},"onreadystatechange"in u&&(u.onreadystatechange=function(){!l&&u.readyState>1&&f()}),u.onload=function(){if(!s){var e;clearTimeout(i);try{e={body:JSON.parse(u.responseText),responseText:u.responseText,statusCode:u.status,headers:u.getAllResponseHeaders&&u.getAllResponseHeaders()||{}}}catch(t){e=new o.UnparsableJSON({more:u.responseText})}e instanceof o.UnparsableJSON?r(e):n(e)}},u.onerror=function(e){s||(clearTimeout(i),r(new o.Network({more:e})))},u instanceof XMLHttpRequest?(u.open(t.method,e,!0),t.forceAuthHeaders&&(u.setRequestHeader("x-algolia-application-id",t.headers["x-algolia-application-id"]),u.setRequestHeader("x-algolia-api-key",t.headers["x-algolia-api-key"]))):u.open(t.method,e),h.cors&&(c&&("POST"===t.method?u.setRequestHeader("content-type","application/x-www-form-urlencoded"):u.setRequestHeader("content-type","application/json")),u.setRequestHeader("accept","application/json")),c?u.send(c):u.send()}else r(new o.Network("CORS not supported"));function d(){s=!0,u.abort(),r(new o.RequestTimeout)}function f(){l=!0,clearTimeout(i),i=setTimeout(d,t.timeouts.complete)}}))},d.prototype._request.fallback=function(e,t){return e=a(e,t.headers),new i((function(n,r){c(e,t,(function(e,t){e?r(e):n(t)}))}))},d.prototype._promise={reject:function(e){return i.reject(e)},resolve:function(e){return i.resolve(e)},delay:function(e){return new i((function(t){setTimeout(t,e)}))},all:function(e){return i.all(e)}},l}},function(e,t,n){(function(t){var n;n="undefined"!=typeof window?window:void 0!==t?t:"undefined"!=typeof self?self:{},e.exports=n}).call(t,n(4))},function(e,t,n){(function(t,n){
+var r;"undefined"!=typeof self&&self,r=function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:r})},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=22)}([function(t,e,n){"use strict";var r,i=n(1);function o(t){return t.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}t.exports={isArray:null,isFunction:null,isObject:null,bind:null,each:null,map:null,mixin:null,isMsie:function(t){if(void 0===t&&(t=navigator.userAgent),/(msie|trident)/i.test(t)){var e=t.match(/(msie |rv:)(\d+(.\d+)?)/i);if(e)return e[2]}return!1},escapeRegExChars:function(t){return t.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")},isNumber:function(t){return"number"==typeof t},toStr:function(t){return null==t?"":t+""},cloneDeep:function(t){var e=this.mixin({},t),n=this;return this.each(e,(function(t,r){t&&(n.isArray(t)?e[r]=[].concat(t):n.isObject(t)&&(e[r]=n.cloneDeep(t)))})),e},error:function(t){throw new Error(t)},every:function(t,e){var n=!0;return t?(this.each(t,(function(r,i){if(!(n=e.call(null,r,i,t)))return!1})),!!n):n},any:function(t,e){var n=!1;return t?(this.each(t,(function(r,i){if(e.call(null,r,i,t))return n=!0,!1})),n):n},getUniqueId:(r=0,function(){return r++}),templatify:function(t){if(this.isFunction(t))return t;var e=i.element(t);return"SCRIPT"===e.prop("tagName")?function(){return e.text()}:function(){return String(t)}},defer:function(t){setTimeout(t,0)},noop:function(){},formatPrefix:function(t,e){return e?"":t+"-"},className:function(t,e,n){return(n?"":".")+t+e},escapeHighlightedString:function(t,e,n){e=e||"<em>";var r=document.createElement("div");r.appendChild(document.createTextNode(e)),n=n||"</em>";var i=document.createElement("div");i.appendChild(document.createTextNode(n));var s=document.createElement("div");return s.appendChild(document.createTextNode(t)),s.innerHTML.replace(RegExp(o(r.innerHTML),"g"),e).replace(RegExp(o(i.innerHTML),"g"),n)}}},function(t,e,n){"use strict";t.exports={element:null}},function(t,e){var n=Object.prototype.hasOwnProperty,r=Object.prototype.toString;t.exports=function(t,e,i){if("[object Function]"!==r.call(e))throw new TypeError("iterator must be a function");var o=t.length;if(o===+o)for(var s=0;s<o;s++)e.call(i,t[s],s,t);else for(var a in t)n.call(t,a)&&e.call(i,t[a],a,t)}},function(t,e){t.exports=function(t){return JSON.parse(JSON.stringify(t))}},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){"use strict";var r=n(12);function i(t,e){var r=n(2),i=this;"function"==typeof Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):i.stack=(new Error).stack||"Cannot get a stacktrace, browser is too old",this.name="AlgoliaSearchError",this.message=t||"Unknown error",e&&r(e,(function(t,e){i[e]=t}))}function o(t,e){function n(){var n=Array.prototype.slice.call(arguments,0);"string"!=typeof n[0]&&n.unshift(e),i.apply(this,n),this.name="AlgoliaSearch"+t+"Error"}return r(n,i),n}r(i,Error),t.exports={AlgoliaSearchError:i,UnparsableJSON:o("UnparsableJSON","Could not parse the incoming response as JSON, see err.more for details"),RequestTimeout:o("RequestTimeout","Request timedout before getting a response"),Network:o("Network","Network issue, see err.more for details"),JSONPScriptFail:o("JSONPScriptFail","<script> was loaded but did not call our provided callback"),JSONPScriptError:o("JSONPScriptError","<script> unable to load due to an `error` event on it"),Unknown:o("Unknown","Unknown error occured")}},function(t,e){var n={}.toString;t.exports=Array.isArray||function(t){return"[object Array]"==n.call(t)}},function(t,e,n){var r=n(2);t.exports=function(t,e){var n=[];return r(t,(function(r,i){n.push(e(r,i,t))})),n}},function(t,e,n){(function(r){function i(){var t;try{t=e.storage.debug}catch(t){}return!t&&void 0!==r&&"env"in r&&(t=Object({NODE_ENV:"production"}).DEBUG),t}(e=t.exports=n(39)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},e.formatArgs=function(t){var n=this.useColors;if(t[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+t[0]+(n?"%c ":" ")+"+"+e.humanize(this.diff),n){var r="color: "+this.color;t.splice(1,0,r,"color: inherit");var i=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(function(t){"%%"!==t&&(i++,"%c"===t&&(o=i))})),t.splice(o,0,r)}},e.save=function(t){try{null==t?e.storage.removeItem("debug"):e.storage.debug=t}catch(t){}},e.load=i,e.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},e.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(t){}}(),e.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],e.formatters.j=function(t){try{return JSON.stringify(t)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}},e.enable(i())}).call(e,n(9))},function(t,e){var n,r,i=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(t){if(n===setTimeout)return setTimeout(t,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(t){n=o}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(t){r=s}}();var u,c=[],l=!1,h=-1;function f(){l&&u&&(l=!1,u.length?c=u.concat(c):h=-1,c.length&&d())}function d(){if(!l){var t=a(f);l=!0;for(var e=c.length;e;){for(u=c,c=[];++h<e;)u&&u[h].run();h=-1,e=c.length}u=null,l=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===s||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function p(t,e){this.fun=t,this.array=e}function g(){}i.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];c.push(new p(t,e)),1!==c.length||l||a(d)},p.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=g,i.addListener=g,i.once=g,i.off=g,i.removeListener=g,i.removeAllListeners=g,i.emit=g,i.prependListener=g,i.prependOnceListener=g,i.listeners=function(t){return[]},i.binding=function(t){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(t){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(t,e,n){"use strict";var r=n(53),i=/\s+/;function o(t,e,n,r){var o;if(!n)return this;for(e=e.split(i),n=r?function(t,e){return t.bind?t.bind(e):function(){t.apply(e,[].slice.call(arguments,0))}}(n,r):n,this._callbacks=this._callbacks||{};o=e.shift();)this._callbacks[o]=this._callbacks[o]||{sync:[],async:[]},this._callbacks[o][t].push(n);return this}function s(t,e,n){return function(){for(var r,i=0,o=t.length;!r&&i<o;i+=1)r=!1===t[i].apply(e,n);return!r}}t.exports={onSync:function(t,e,n){return o.call(this,"sync",t,e,n)},onAsync:function(t,e,n){return o.call(this,"async",t,e,n)},off:function(t){var e;if(!this._callbacks)return this;for(t=t.split(i);e=t.shift();)delete this._callbacks[e];return this},trigger:function(t){var e,n,o,a,u;if(!this._callbacks)return this;for(t=t.split(i),o=[].slice.call(arguments,1);(e=t.shift())&&(n=this._callbacks[e]);)a=s(n.sync,this,[e].concat(o)),u=s(n.async,this,[e].concat(o)),a()&&r(u);return this}}},function(t,e,n){"use strict";var r=n(0),i={wrapper:{position:"relative",display:"inline-block"},hint:{position:"absolute",top:"0",left:"0",borderColor:"transparent",boxShadow:"none",opacity:"1"},input:{position:"relative",verticalAlign:"top",backgroundColor:"transparent"},inputWithNoHint:{position:"relative",verticalAlign:"top"},dropdown:{position:"absolute",top:"100%",left:"0",zIndex:"100",display:"none"},suggestions:{display:"block"},suggestion:{whiteSpace:"nowrap",cursor:"pointer"},suggestionChild:{whiteSpace:"normal"},ltr:{left:"0",right:"auto"},rtl:{left:"auto",right:"0"},defaultClasses:{root:"algolia-autocomplete",prefix:"aa",noPrefix:!1,dropdownMenu:"dropdown-menu",input:"input",hint:"hint",suggestions:"suggestions",suggestion:"suggestion",cursor:"cursor",dataset:"dataset",empty:"empty"},appendTo:{wrapper:{position:"absolute",zIndex:"100",display:"none"},input:{},inputWithNoHint:{},dropdown:{display:"block"}}};r.isMsie()&&r.mixin(i.input,{backgroundImage:"url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)"}),r.isMsie()&&r.isMsie()<=7&&r.mixin(i.input,{marginTop:"-1px"}),t.exports=i},function(t,e){"function"==typeof Object.create?t.exports=function(t,e){t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}:t.exports=function(t,e){t.super_=e;var n=function(){};n.prototype=e.prototype,t.prototype=new n,t.prototype.constructor=t}},function(t,e,n){t.exports=function(t,e){return function(n,i,o){if("function"==typeof n&&"object"==typeof i||"object"==typeof o)throw new r.AlgoliaSearchError("index.search usage is index.search(query, params, cb)");0===arguments.length||"function"==typeof n?(o=n,n=""):1!==arguments.length&&"function"!=typeof i||(o=i,i=void 0),"object"==typeof n&&null!==n?(i=n,n=void 0):null==n&&(n="");var s,a="";return void 0!==n&&(a+=t+"="+encodeURIComponent(n)),void 0!==i&&(i.additionalUA&&(s=i.additionalUA,delete i.additionalUA),a=this.as._getSearchParams(i,a)),this._search(a,e,o,s)}};var r=n(5)},function(t,e,n){t.exports=function(t,e){var r=n(36),i=n(2),o={};return i(r(t),(function(n){!0!==e(n)&&(o[n]=t[n])})),o}},function(t,e){var n;n=window,t.exports=function(t){var e,n,r=function(){var e,n,r,i,o,s=[],a=s.concat,u=s.filter,c=s.slice,l=t.document,h={},f={},d={"column-count":1,columns:1,"font-weight":1,"line-height":1,opacity:1,"z-index":1,zoom:1},p=/^\s*<(\w+|!)[^>]*>/,g=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,m=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,y=/^(?:body|html)$/i,v=/([A-Z])/g,b=["val","css","html","text","data","width","height","offset"],w=l.createElement("table"),_=l.createElement("tr"),x={tr:l.createElement("tbody"),tbody:w,thead:w,tfoot:w,td:_,th:_,"*":l.createElement("div")},S=/complete|loaded|interactive/,C=/^[\w-]*$/,A={},E=A.toString,T={},k=l.createElement("div"),O={tabindex:"tabIndex",readonly:"readOnly",for:"htmlFor",class:"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},N=Array.isArray||function(t){return t instanceof Array};function j(t){return null==t?String(t):A[E.call(t)]||"object"}function I(t){return"function"==j(t)}function R(t){return null!=t&&t==t.window}function L(t){return null!=t&&t.nodeType==t.DOCUMENT_NODE}function P(t){return"object"==j(t)}function D(t){return P(t)&&!R(t)&&Object.getPrototypeOf(t)==Object.prototype}function $(t){var e=!!t&&"length"in t&&t.length,r=n.type(t);return"function"!=r&&!R(t)&&("array"==r||0===e||"number"==typeof e&&e>0&&e-1 in t)}function q(t){return t.replace(/::/g,"/").replace(/([A-Z]+)([A-Z][a-z])/g,"$1_$2").replace(/([a-z\d])([A-Z])/g,"$1_$2").replace(/_/g,"-").toLowerCase()}function M(t){return t in f?f[t]:f[t]=new RegExp("(^|\\s)"+t+"(\\s|$)")}function H(t,e){return"number"!=typeof e||d[q(t)]?e:e+"px"}function F(t){return"children"in t?c.call(t.children):n.map(t.childNodes,(function(t){if(1==t.nodeType)return t}))}function z(t,e){var n,r=t?t.length:0;for(n=0;n<r;n++)this[n]=t[n];this.length=r,this.selector=e||""}function B(t,n,r){for(e in n)r&&(D(n[e])||N(n[e]))?(D(n[e])&&!D(t[e])&&(t[e]={}),N(n[e])&&!N(t[e])&&(t[e]=[]),B(t[e],n[e],r)):void 0!==n[e]&&(t[e]=n[e])}function U(t,e){return null==e?n(t):n(t).filter(e)}function V(t,e,n,r){return I(e)?e.call(t,n,r):e}function K(t,e,n){null==n?t.removeAttribute(e):t.setAttribute(e,n)}function J(t,e){var n=t.className||"",r=n&&void 0!==n.baseVal;if(void 0===e)return r?n.baseVal:n;r?n.baseVal=e:t.className=e}function W(t){try{return t?"true"==t||"false"!=t&&("null"==t?null:+t+""==t?+t:/^[\[\{]/.test(t)?n.parseJSON(t):t):t}catch(e){return t}}function X(t,e){e(t);for(var n=0,r=t.childNodes.length;n<r;n++)X(t.childNodes[n],e)}return T.matches=function(t,e){if(!e||!t||1!==t.nodeType)return!1;var n=t.matches||t.webkitMatchesSelector||t.mozMatchesSelector||t.oMatchesSelector||t.matchesSelector;if(n)return n.call(t,e);var r,i=t.parentNode,o=!i;return o&&(i=k).appendChild(t),r=~T.qsa(i,e).indexOf(t),o&&k.removeChild(t),r},i=function(t){return t.replace(/-+(.)?/g,(function(t,e){return e?e.toUpperCase():""}))},o=function(t){return u.call(t,(function(e,n){return t.indexOf(e)==n}))},T.fragment=function(t,e,r){var i,o,s;return g.test(t)&&(i=n(l.createElement(RegExp.$1))),i||(t.replace&&(t=t.replace(m,"<$1></$2>")),void 0===e&&(e=p.test(t)&&RegExp.$1),e in x||(e="*"),(s=x[e]).innerHTML=""+t,i=n.each(c.call(s.childNodes),(function(){s.removeChild(this)}))),D(r)&&(o=n(i),n.each(r,(function(t,e){b.indexOf(t)>-1?o[t](e):o.attr(t,e)}))),i},T.Z=function(t,e){return new z(t,e)},T.isZ=function(t){return t instanceof T.Z},T.init=function(t,e){var r,i;if(!t)return T.Z();if("string"==typeof t)if("<"==(t=t.trim())[0]&&p.test(t))r=T.fragment(t,RegExp.$1,e),t=null;else{if(void 0!==e)return n(e).find(t);r=T.qsa(l,t)}else{if(I(t))return n(l).ready(t);if(T.isZ(t))return t;if(N(t))i=t,r=u.call(i,(function(t){return null!=t}));else if(P(t))r=[t],t=null;else if(p.test(t))r=T.fragment(t.trim(),RegExp.$1,e),t=null;else{if(void 0!==e)return n(e).find(t);r=T.qsa(l,t)}}return T.Z(r,t)},(n=function(t,e){return T.init(t,e)}).extend=function(t){var e,n=c.call(arguments,1);return"boolean"==typeof t&&(e=t,t=n.shift()),n.forEach((function(n){B(t,n,e)})),t},T.qsa=function(t,e){var n,r="#"==e[0],i=!r&&"."==e[0],o=r||i?e.slice(1):e,s=C.test(o);return t.getElementById&&s&&r?(n=t.getElementById(o))?[n]:[]:1!==t.nodeType&&9!==t.nodeType&&11!==t.nodeType?[]:c.call(s&&!r&&t.getElementsByClassName?i?t.getElementsByClassName(o):t.getElementsByTagName(e):t.querySelectorAll(e))},n.contains=l.documentElement.contains?function(t,e){return t!==e&&t.contains(e)}:function(t,e){for(;e&&(e=e.parentNode);)if(e===t)return!0;return!1},n.type=j,n.isFunction=I,n.isWindow=R,n.isArray=N,n.isPlainObject=D,n.isEmptyObject=function(t){var e;for(e in t)return!1;return!0},n.isNumeric=function(t){var e=Number(t),n=typeof t;return null!=t&&"boolean"!=n&&("string"!=n||t.length)&&!isNaN(e)&&isFinite(e)||!1},n.inArray=function(t,e,n){return s.indexOf.call(e,t,n)},n.camelCase=i,n.trim=function(t){return null==t?"":String.prototype.trim.call(t)},n.uuid=0,n.support={},n.expr={},n.noop=function(){},n.map=function(t,e){var r,i,o,s,a=[];if($(t))for(i=0;i<t.length;i++)null!=(r=e(t[i],i))&&a.push(r);else for(o in t)null!=(r=e(t[o],o))&&a.push(r);return(s=a).length>0?n.fn.concat.apply([],s):s},n.each=function(t,e){var n,r;if($(t)){for(n=0;n<t.length;n++)if(!1===e.call(t[n],n,t[n]))return t}else for(r in t)if(!1===e.call(t[r],r,t[r]))return t;return t},n.grep=function(t,e){return u.call(t,e)},t.JSON&&(n.parseJSON=JSON.parse),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),(function(t,e){A["[object "+e+"]"]=e.toLowerCase()})),n.fn={constructor:T.Z,length:0,forEach:s.forEach,reduce:s.reduce,push:s.push,sort:s.sort,splice:s.splice,indexOf:s.indexOf,concat:function(){var t,e,n=[];for(t=0;t<arguments.length;t++)e=arguments[t],n[t]=T.isZ(e)?e.toArray():e;return a.apply(T.isZ(this)?this.toArray():this,n)},map:function(t){return n(n.map(this,(function(e,n){return t.call(e,n,e)})))},slice:function(){return n(c.apply(this,arguments))},ready:function(t){return S.test(l.readyState)&&l.body?t(n):l.addEventListener("DOMContentLoaded",(function(){t(n)}),!1),this},get:function(t){return void 0===t?c.call(this):this[t>=0?t:t+this.length]},toArray:function(){return this.get()},size:function(){return this.length},remove:function(){return this.each((function(){null!=this.parentNode&&this.parentNode.removeChild(this)}))},each:function(t){return s.every.call(this,(function(e,n){return!1!==t.call(e,n,e)})),this},filter:function(t){return I(t)?this.not(this.not(t)):n(u.call(this,(function(e){return T.matches(e,t)})))},add:function(t,e){return n(o(this.concat(n(t,e))))},is:function(t){return this.length>0&&T.matches(this[0],t)},not:function(t){var e=[];if(I(t)&&void 0!==t.call)this.each((function(n){t.call(this,n)||e.push(this)}));else{var r="string"==typeof t?this.filter(t):$(t)&&I(t.item)?c.call(t):n(t);this.forEach((function(t){r.indexOf(t)<0&&e.push(t)}))}return n(e)},has:function(t){return this.filter((function(){return P(t)?n.contains(this,t):n(this).find(t).size()}))},eq:function(t){return-1===t?this.slice(t):this.slice(t,+t+1)},first:function(){var t=this[0];return t&&!P(t)?t:n(t)},last:function(){var t=this[this.length-1];return t&&!P(t)?t:n(t)},find:function(t){var e=this;return t?"object"==typeof t?n(t).filter((function(){var t=this;return s.some.call(e,(function(e){return n.contains(e,t)}))})):1==this.length?n(T.qsa(this[0],t)):this.map((function(){return T.qsa(this,t)})):n()},closest:function(t,e){var r=[],i="object"==typeof t&&n(t);return this.each((function(n,o){for(;o&&!(i?i.indexOf(o)>=0:T.matches(o,t));)o=o!==e&&!L(o)&&o.parentNode;o&&r.indexOf(o)<0&&r.push(o)})),n(r)},parents:function(t){for(var e=[],r=this;r.length>0;)r=n.map(r,(function(t){if((t=t.parentNode)&&!L(t)&&e.indexOf(t)<0)return e.push(t),t}));return U(e,t)},parent:function(t){return U(o(this.pluck("parentNode")),t)},children:function(t){return U(this.map((function(){return F(this)})),t)},contents:function(){return this.map((function(){return this.contentDocument||c.call(this.childNodes)}))},siblings:function(t){return U(this.map((function(t,e){return u.call(F(e.parentNode),(function(t){return t!==e}))})),t)},empty:function(){return this.each((function(){this.innerHTML=""}))},pluck:function(t){return n.map(this,(function(e){return e[t]}))},show:function(){return this.each((function(){var t,e,n;"none"==this.style.display&&(this.style.display=""),"none"==getComputedStyle(this,"").getPropertyValue("display")&&(this.style.display=(t=this.nodeName,h[t]||(e=l.createElement(t),l.body.appendChild(e),n=getComputedStyle(e,"").getPropertyValue("display"),e.parentNode.removeChild(e),"none"==n&&(n="block"),h[t]=n),h[t]))}))},replaceWith:function(t){return this.before(t).remove()},wrap:function(t){var e=I(t);if(this[0]&&!e)var r=n(t).get(0),i=r.parentNode||this.length>1;return this.each((function(o){n(this).wrapAll(e?t.call(this,o):i?r.cloneNode(!0):r)}))},wrapAll:function(t){if(this[0]){var e;for(n(this[0]).before(t=n(t));(e=t.children()).length;)t=e.first();n(t).append(this)}return this},wrapInner:function(t){var e=I(t);return this.each((function(r){var i=n(this),o=i.contents(),s=e?t.call(this,r):t;o.length?o.wrapAll(s):i.append(s)}))},unwrap:function(){return this.parent().each((function(){n(this).replaceWith(n(this).children())})),this},clone:function(){return this.map((function(){return this.cloneNode(!0)}))},hide:function(){return this.css("display","none")},toggle:function(t){return this.each((function(){var e=n(this);(void 0===t?"none"==e.css("display"):t)?e.show():e.hide()}))},prev:function(t){return n(this.pluck("previousElementSibling")).filter(t||"*")},next:function(t){return n(this.pluck("nextElementSibling")).filter(t||"*")},html:function(t){return 0 in arguments?this.each((function(e){var r=this.innerHTML;n(this).empty().append(V(this,t,e,r))})):0 in this?this[0].innerHTML:null},text:function(t){return 0 in arguments?this.each((function(e){var n=V(this,t,e,this.textContent);this.textContent=null==n?"":""+n})):0 in this?this.pluck("textContent").join(""):null},attr:function(t,n){var r;return"string"!=typeof t||1 in arguments?this.each((function(r){if(1===this.nodeType)if(P(t))for(e in t)K(this,e,t[e]);else K(this,t,V(this,n,r,this.getAttribute(t)))})):0 in this&&1==this[0].nodeType&&null!=(r=this[0].getAttribute(t))?r:void 0},removeAttr:function(t){return this.each((function(){1===this.nodeType&&t.split(" ").forEach((function(t){K(this,t)}),this)}))},prop:function(t,e){return t=O[t]||t,1 in arguments?this.each((function(n){this[t]=V(this,e,n,this[t])})):this[0]&&this[0][t]},removeProp:function(t){return t=O[t]||t,this.each((function(){delete this[t]}))},data:function(t,e){var n="data-"+t.replace(v,"-$1").toLowerCase(),r=1 in arguments?this.attr(n,e):this.attr(n);return null!==r?W(r):void 0},val:function(t){return 0 in arguments?(null==t&&(t=""),this.each((function(e){this.value=V(this,t,e,this.value)}))):this[0]&&(this[0].multiple?n(this[0]).find("option").filter((function(){return this.selected})).pluck("value"):this[0].value)},offset:function(e){if(e)return this.each((function(t){var r=n(this),i=V(this,e,t,r.offset()),o=r.offsetParent().offset(),s={top:i.top-o.top,left:i.left-o.left};"static"==r.css("position")&&(s.position="relative"),r.css(s)}));if(!this.length)return null;if(l.documentElement!==this[0]&&!n.contains(l.documentElement,this[0]))return{top:0,left:0};var r=this[0].getBoundingClientRect();return{left:r.left+t.pageXOffset,top:r.top+t.pageYOffset,width:Math.round(r.width),height:Math.round(r.height)}},css:function(t,r){if(arguments.length<2){var o=this[0];if("string"==typeof t){if(!o)return;return o.style[i(t)]||getComputedStyle(o,"").getPropertyValue(t)}if(N(t)){if(!o)return;var s={},a=getComputedStyle(o,"");return n.each(t,(function(t,e){s[e]=o.style[i(e)]||a.getPropertyValue(e)})),s}}var u="";if("string"==j(t))r||0===r?u=q(t)+":"+H(t,r):this.each((function(){this.style.removeProperty(q(t))}));else for(e in t)t[e]||0===t[e]?u+=q(e)+":"+H(e,t[e])+";":this.each((function(){this.style.removeProperty(q(e))}));return this.each((function(){this.style.cssText+=";"+u}))},index:function(t){return t?this.indexOf(n(t)[0]):this.parent().children().indexOf(this[0])},hasClass:function(t){return!!t&&s.some.call(this,(function(t){return this.test(J(t))}),M(t))},addClass:function(t){return t?this.each((function(e){if("className"in this){r=[];var i=J(this);V(this,t,e,i).split(/\s+/g).forEach((function(t){n(this).hasClass(t)||r.push(t)}),this),r.length&&J(this,i+(i?" ":"")+r.join(" "))}})):this},removeClass:function(t){return this.each((function(e){if("className"in this){if(void 0===t)return J(this,"");r=J(this),V(this,t,e,r).split(/\s+/g).forEach((function(t){r=r.replace(M(t)," ")})),J(this,r.trim())}}))},toggleClass:function(t,e){return t?this.each((function(r){var i=n(this);V(this,t,r,J(this)).split(/\s+/g).forEach((function(t){(void 0===e?!i.hasClass(t):e)?i.addClass(t):i.removeClass(t)}))})):this},scrollTop:function(t){if(this.length){var e="scrollTop"in this[0];return void 0===t?e?this[0].scrollTop:this[0].pageYOffset:this.each(e?function(){this.scrollTop=t}:function(){this.scrollTo(this.scrollX,t)})}},scrollLeft:function(t){if(this.length){var e="scrollLeft"in this[0];return void 0===t?e?this[0].scrollLeft:this[0].pageXOffset:this.each(e?function(){this.scrollLeft=t}:function(){this.scrollTo(t,this.scrollY)})}},position:function(){if(this.length){var t=this[0],e=this.offsetParent(),r=this.offset(),i=y.test(e[0].nodeName)?{top:0,left:0}:e.offset();return r.top-=parseFloat(n(t).css("margin-top"))||0,r.left-=parseFloat(n(t).css("margin-left"))||0,i.top+=parseFloat(n(e[0]).css("border-top-width"))||0,i.left+=parseFloat(n(e[0]).css("border-left-width"))||0,{top:r.top-i.top,left:r.left-i.left}}},offsetParent:function(){return this.map((function(){for(var t=this.offsetParent||l.body;t&&!y.test(t.nodeName)&&"static"==n(t).css("position");)t=t.offsetParent;return t}))}},n.fn.detach=n.fn.remove,["width","height"].forEach((function(t){var e=t.replace(/./,(function(t){return t[0].toUpperCase()}));n.fn[t]=function(r){var i,o=this[0];return void 0===r?R(o)?o["inner"+e]:L(o)?o.documentElement["scroll"+e]:(i=this.offset())&&i[t]:this.each((function(e){(o=n(this)).css(t,V(this,r,e,o[t]()))}))}})),["after","prepend","before","append"].forEach((function(e,r){var i=r%2;n.fn[e]=function(){var e,o,s=n.map(arguments,(function(t){var r=[];return"array"==(e=j(t))?(t.forEach((function(t){return void 0!==t.nodeType?r.push(t):n.zepto.isZ(t)?r=r.concat(t.get()):void(r=r.concat(T.fragment(t)))})),r):"object"==e||null==t?t:T.fragment(t)})),a=this.length>1;return s.length<1?this:this.each((function(e,u){o=i?u:u.parentNode,u=0==r?u.nextSibling:1==r?u.firstChild:2==r?u:null;var c=n.contains(l.documentElement,o);s.forEach((function(e){if(a)e=e.cloneNode(!0);else if(!o)return n(e).remove();o.insertBefore(e,u),c&&X(e,(function(e){if(!(null==e.nodeName||"SCRIPT"!==e.nodeName.toUpperCase()||e.type&&"text/javascript"!==e.type||e.src)){var n=e.ownerDocument?e.ownerDocument.defaultView:t;n.eval.call(n,e.innerHTML)}}))}))}))},n.fn[i?e+"To":"insert"+(r?"Before":"After")]=function(t){return n(t)[e](this),this}})),T.Z.prototype=z.prototype=n.fn,T.uniq=o,T.deserializeValue=W,n.zepto=T,n}();return function(e){var n=1,r=Array.prototype.slice,i=e.isFunction,o=function(t){return"string"==typeof t},s={},a={},u="onfocusin"in t,c={focus:"focusin",blur:"focusout"},l={mouseenter:"mouseover",mouseleave:"mouseout"};function h(t){return t._zid||(t._zid=n++)}function f(t,e,n,r){if((e=d(e)).ns)var i=(o=e.ns,new RegExp("(?:^| )"+o.replace(" "," .* ?")+"(?: |$)"));var o;return(s[h(t)]||[]).filter((function(t){return t&&(!e.e||t.e==e.e)&&(!e.ns||i.test(t.ns))&&(!n||h(t.fn)===h(n))&&(!r||t.sel==r)}))}function d(t){var e=(""+t).split(".");return{e:e[0],ns:e.slice(1).sort().join(" ")}}function p(t,e){return t.del&&!u&&t.e in c||!!e}function g(t){return l[t]||u&&c[t]||t}function m(t,n,r,i,o,a,u){var c=h(t),f=s[c]||(s[c]=[]);n.split(/\s/).forEach((function(n){if("ready"==n)return e(document).ready(r);var s=d(n);s.fn=r,s.sel=o,s.e in l&&(r=function(t){var n=t.relatedTarget;if(!n||n!==this&&!e.contains(this,n))return s.fn.apply(this,arguments)}),s.del=a;var c=a||r;s.proxy=function(e){if(!(e=x(e)).isImmediatePropagationStopped()){try{var n=Object.getOwnPropertyDescriptor(e,"data");n&&!n.writable||(e.data=i)}catch(e){}var r=c.apply(t,null==e._args?[e]:[e].concat(e._args));return!1===r&&(e.preventDefault(),e.stopPropagation()),r}},s.i=f.length,f.push(s),"addEventListener"in t&&t.addEventListener(g(s.e),s.proxy,p(s,u))}))}function y(t,e,n,r,i){var o=h(t);(e||"").split(/\s/).forEach((function(e){f(t,e,n,r).forEach((function(e){delete s[o][e.i],"removeEventListener"in t&&t.removeEventListener(g(e.e),e.proxy,p(e,i))}))}))}a.click=a.mousedown=a.mouseup=a.mousemove="MouseEvents",e.event={add:m,remove:y},e.proxy=function(t,n){var s=2 in arguments&&r.call(arguments,2);if(i(t)){var a=function(){return t.apply(n,s?s.concat(r.call(arguments)):arguments)};return a._zid=h(t),a}if(o(n))return s?(s.unshift(t[n],t),e.proxy.apply(null,s)):e.proxy(t[n],t);throw new TypeError("expected function")},e.fn.bind=function(t,e,n){return this.on(t,e,n)},e.fn.unbind=function(t,e){return this.off(t,e)},e.fn.one=function(t,e,n,r){return this.on(t,e,n,r,1)};var v=function(){return!0},b=function(){return!1},w=/^([A-Z]|returnValue$|layer[XY]$|webkitMovement[XY]$)/,_={preventDefault:"isDefaultPrevented",stopImmediatePropagation:"isImmediatePropagationStopped",stopPropagation:"isPropagationStopped"};function x(t,n){return!n&&t.isDefaultPrevented||(n||(n=t),e.each(_,(function(e,r){var i=n[e];t[e]=function(){return this[r]=v,i&&i.apply(n,arguments)},t[r]=b})),t.timeStamp||(t.timeStamp=Date.now()),(void 0!==n.defaultPrevented?n.defaultPrevented:"returnValue"in n?!1===n.returnValue:n.getPreventDefault&&n.getPreventDefault())&&(t.isDefaultPrevented=v)),t}function S(t){var e,n={originalEvent:t};for(e in t)w.test(e)||void 0===t[e]||(n[e]=t[e]);return x(n,t)}e.fn.delegate=function(t,e,n){return this.on(e,t,n)},e.fn.undelegate=function(t,e,n){return this.off(e,t,n)},e.fn.live=function(t,n){return e(document.body).delegate(this.selector,t,n),this},e.fn.die=function(t,n){return e(document.body).undelegate(this.selector,t,n),this},e.fn.on=function(t,n,s,a,u){var c,l,h=this;return t&&!o(t)?(e.each(t,(function(t,e){h.on(t,n,s,e,u)})),h):(o(n)||i(a)||!1===a||(a=s,s=n,n=void 0),void 0!==a&&!1!==s||(a=s,s=void 0),!1===a&&(a=b),h.each((function(i,o){u&&(c=function(t){return y(o,t.type,a),a.apply(this,arguments)}),n&&(l=function(t){var i,s=e(t.target).closest(n,o).get(0);if(s&&s!==o)return i=e.extend(S(t),{currentTarget:s,liveFired:o}),(c||a).apply(s,[i].concat(r.call(arguments,1)))}),m(o,t,a,s,n,l||c)})))},e.fn.off=function(t,n,r){var s=this;return t&&!o(t)?(e.each(t,(function(t,e){s.off(t,n,e)})),s):(o(n)||i(r)||!1===r||(r=n,n=void 0),!1===r&&(r=b),s.each((function(){y(this,t,r,n)})))},e.fn.trigger=function(t,n){return(t=o(t)||e.isPlainObject(t)?e.Event(t):x(t))._args=n,this.each((function(){t.type in c&&"function"==typeof this[t.type]?this[t.type]():"dispatchEvent"in this?this.dispatchEvent(t):e(this).triggerHandler(t,n)}))},e.fn.triggerHandler=function(t,n){var r,i;return this.each((function(s,a){(r=S(o(t)?e.Event(t):t))._args=n,r.target=a,e.each(f(a,t.type||t),(function(t,e){if(i=e.proxy(r),r.isImmediatePropagationStopped())return!1}))})),i},"focusin focusout focus blur load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select keydown keypress keyup error".split(" ").forEach((function(t){e.fn[t]=function(e){return 0 in arguments?this.bind(t,e):this.trigger(t)}})),e.Event=function(t,e){o(t)||(t=(e=t).type);var n=document.createEvent(a[t]||"Events"),r=!0;if(e)for(var i in e)"bubbles"==i?r=!!e[i]:n[i]=e[i];return n.initEvent(t,r,!0),x(n)}}(r),n=[],r.fn.remove=function(){return this.each((function(){this.parentNode&&("IMG"===this.tagName&&(n.push(this),this.src="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=",e&&clearTimeout(e),e=setTimeout((function(){n=[]}),6e4)),this.parentNode.removeChild(this))}))},function(t){var e={},n=t.fn.data,r=t.camelCase,i=t.expando="Zepto"+ +new Date,o=[];function s(n,s,a){var u=n[i]||(n[i]=++t.uuid),c=e[u]||(e[u]=function(e){var n={};return t.each(e.attributes||o,(function(e,i){0==i.name.indexOf("data-")&&(n[r(i.name.replace("data-",""))]=t.zepto.deserializeValue(i.value))})),n}(n));return void 0!==s&&(c[r(s)]=a),c}t.fn.data=function(o,a){return void 0===a?t.isPlainObject(o)?this.each((function(e,n){t.each(o,(function(t,e){s(n,t,e)}))})):0 in this?function(o,a){var u=o[i],c=u&&e[u];if(void 0===a)return c||s(o);if(c){if(a in c)return c[a];var l=r(a);if(l in c)return c[l]}return n.call(t(o),a)}(this[0],o):void 0:this.each((function(){s(this,o,a)}))},t.data=function(e,n,r){return t(e).data(n,r)},t.hasData=function(n){var r=n[i],o=r&&e[r];return!!o&&!t.isEmptyObject(o)},t.fn.removeData=function(n){return"string"==typeof n&&(n=n.split(/\s+/)),this.each((function(){var o=this[i],s=o&&e[o];s&&t.each(n||s,(function(t){delete s[n?r(this):t]}))}))},["remove","empty"].forEach((function(e){var n=t.fn[e];t.fn[e]=function(){var t=this.find("*");return"remove"===e&&(t=t.add(this)),t.removeData(),n.call(this)}}))}(r),r}(n)},function(t,e,n){"use strict";var r=n(0),i=n(1);function o(t){t&&t.el||r.error("EventBus initialized without el"),this.$el=i.element(t.el)}r.mixin(o.prototype,{trigger:function(t){var e=[].slice.call(arguments,1),n=r.Event("autocomplete:"+t);return this.$el.trigger(n,e),n}}),t.exports=o},function(t,e,n){"use strict";t.exports={wrapper:'<span class="%ROOT%"></span>',dropdown:'<span class="%PREFIX%%DROPDOWN_MENU%"></span>',dataset:'<div class="%PREFIX%%DATASET%-%CLASS%"></div>',suggestions:'<span class="%PREFIX%%SUGGESTIONS%"></span>',suggestion:'<div class="%PREFIX%%SUGGESTION%"></div>'}},function(t,e){t.exports="0.32.0"},function(t,e,n){"use strict";t.exports=function(t){var e=t.match(/Algolia for vanilla JavaScript (\d+\.)(\d+\.)(\d+)/);if(e)return[e[1],e[2],e[3]]}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(15),o=(r=i)&&r.__esModule?r:{default:r};e.default=o.default},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default="2.6.1"},function(t,e,n){"use strict";var r,i=n(23),o=(r=i)&&r.__esModule?r:{default:r};t.exports=o.default},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=s(n(24)),i=s(n(25)),o=s(n(21));function s(t){return t&&t.__esModule?t:{default:t}}var a=(0,r.default)(i.default);a.version=o.default,e.default=a},function(t,e,n){"use strict";var r=Function.prototype.bind;t.exports=function(t){var e=function(){for(var e=arguments.length,n=Array(e),i=0;i<e;i++)n[i]=arguments[i];return new(r.apply(t,[null].concat(n)))};return e.__proto__=t,e.prototype=t.prototype,e}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},i=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),o=f(n(26)),s=f(n(29)),a=f(n(49)),u=f(n(64)),c=f(n(65)),l=f(n(21)),h=f(n(20));function f(t){return t&&t.__esModule?t:{default:t}}var d=function(){function t(e){var n=e.apiKey,i=e.indexName,o=e.inputSelector,c=e.appId,f=void 0===c?"BH4D9OD16A":c,d=e.debug,p=void 0!==d&&d,g=e.algoliaOptions,m=void 0===g?{}:g,y=e.autocompleteOptions,v=void 0===y?{debug:!1,hint:!1,autoselect:!0}:y,b=e.transformData,w=void 0!==b&&b,_=e.queryHook,x=void 0!==_&&_,S=e.handleSelected,C=void 0!==S&&S,A=e.enhancedSearchInput,E=void 0!==A&&A,T=e.layout,k=void 0===T?"collumns":T;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),t.checkArguments({apiKey:n,indexName:i,inputSelector:o,debug:p,algoliaOptions:m,autocompleteOptions:v,transformData:w,queryHook:x,handleSelected:C,enhancedSearchInput:E,layout:k}),this.apiKey=n,this.appId=f,this.indexName=i,this.input=t.getInputFromSelector(o),this.algoliaOptions=r({hitsPerPage:5},m);var O=!(!v||!v.debug)&&v.debug;v.debug=p||O,this.autocompleteOptions=v,this.autocompleteOptions.cssClasses=this.autocompleteOptions.cssClasses||{},this.autocompleteOptions.cssClasses.prefix=this.autocompleteOptions.cssClasses.prefix||"ds",C=C||this.handleSelected,this.isSimpleLayout="simple"===k,this.client=(0,s.default)(this.appId,this.apiKey),this.client.addAlgoliaAgent("docsearch.js "+l.default),E&&(this.input=t.injectSearchBox(this.input)),this.autocomplete=(0,a.default)(this.input,v,[{source:this.getAutocompleteSource(w,x),templates:{suggestion:t.getSuggestionTemplate(this.isSimpleLayout),footer:u.default.footer,empty:t.getEmptyTemplate()}}]),C&&(0,h.default)(".algolia-autocomplete").on("click",".ds-suggestions a",(function(t){t.preventDefault()})),this.autocomplete.on("autocomplete:selected",C.bind(null,this.autocomplete.autocomplete)),this.autocomplete.on("autocomplete:shown",this.handleShown.bind(null,this.input)),E&&t.bindSearchBoxEvent()}return i(t,[{key:"getAutocompleteSource",value:function(e,n){var r=this;return function(i,o){n&&(i=n(i)||i),r.client.search([{indexName:r.indexName,query:i,params:r.algoliaOptions}]).then((function(n){var r=n.results[0].hits;e&&(r=e(r)||r),o(t.formatHits(r))}))}}},{key:"handleSelected",value:function(t,e,n){t.setVal(""),window.location.assign(n.url)}},{key:"handleShown",value:function(t){var e=t.offset().left+t.width()/2,n=(0,h.default)(document).width()/2;isNaN(n)&&(n=900);var r=e-n>=0?"algolia-autocomplete-right":"algolia-autocomplete-left",i=e-n<0?"algolia-autocomplete-right":"algolia-autocomplete-left",o=(0,h.default)(".algolia-autocomplete");o.hasClass(r)||o.addClass(r),o.hasClass(i)&&o.removeClass(i)}}],[{key:"checkArguments",value:function(e){if(!e.apiKey||!e.indexName)throw new Error("Usage:\n documentationSearch({\n apiKey,\n indexName,\n inputSelector,\n [ appId ],\n [ algoliaOptions.{hitsPerPage} ]\n [ autocompleteOptions.{hint,debug} ]\n})");if("string"!=typeof e.inputSelector)throw new Error("Error: inputSelector:"+e.inputSelector+" must be a string. Each selector must match only one element and separated by ','");if(!t.getInputFromSelector(e.inputSelector))throw new Error("Error: No input element in the page matches "+e.inputSelector)}},{key:"injectSearchBox",value:function(t){t.before(u.default.searchBox);var e=t.prev().prev().find("input");return t.remove(),e}},{key:"bindSearchBoxEvent",value:function(){(0,h.default)('.searchbox [type="reset"]').on("click",(function(){(0,h.default)("input#docsearch").focus(),(0,h.default)(this).addClass("hide"),a.default.autocomplete.setVal("")})),(0,h.default)("input#docsearch").on("keyup",(function(){var t=document.querySelector("input#docsearch"),e=document.querySelector('.searchbox [type="reset"]');e.className="searchbox__reset",0===t.value.length&&(e.className+=" hide")}))}},{key:"getInputFromSelector",value:function(t){var e=(0,h.default)(t).filter("input");return e.length?(0,h.default)(e[0]):null}},{key:"formatHits",value:function(e){var n=c.default.deepClone(e).map((function(t){return t._highlightResult&&(t._highlightResult=c.default.mergeKeyWithParent(t._highlightResult,"hierarchy")),c.default.mergeKeyWithParent(t,"hierarchy")})),r=c.default.groupBy(n,"lvl0");return h.default.each(r,(function(t,e){var n=c.default.groupBy(e,"lvl1"),i=c.default.flattenAndFlagFirst(n,"isSubCategoryHeader");r[t]=i})),(r=c.default.flattenAndFlagFirst(r,"isCategoryHeader")).map((function(e){var n=t.formatURL(e),r=c.default.getHighlightedValue(e,"lvl0"),i=c.default.getHighlightedValue(e,"lvl1")||r,o=c.default.compact([c.default.getHighlightedValue(e,"lvl2")||i,c.default.getHighlightedValue(e,"lvl3"),c.default.getHighlightedValue(e,"lvl4"),c.default.getHighlightedValue(e,"lvl5"),c.default.getHighlightedValue(e,"lvl6")]).join('<span class="aa-suggestion-title-separator" aria-hidden="true"> › </span>'),s=c.default.getSnippetedValue(e,"content"),a=i&&""!==i||o&&""!==o,u=o&&""!==o&&o!==i,l=!u&&i&&""!==i&&i!==r;return{isLvl0:!l&&!u,isLvl1:l,isLvl2:u,isLvl1EmptyOrDuplicate:!i||""===i||i===r,isCategoryHeader:e.isCategoryHeader,isSubCategoryHeader:e.isSubCategoryHeader,isTextOrSubcategoryNonEmpty:a,category:r,subcategory:i,title:o,text:s,url:n}}))}},{key:"formatURL",value:function(t){var e=t.url,n=t.anchor;return e?-1!==e.indexOf("#")?e:n?t.url+"#"+t.anchor:e:n?"#"+t.anchor:(console.warn("no anchor nor url for : ",JSON.stringify(t)),null)}},{key:"getEmptyTemplate",value:function(){return function(t){return o.default.compile(u.default.empty).render(t)}}},{key:"getSuggestionTemplate",value:function(t){var e=t?u.default.suggestionSimple:u.default.suggestion,n=o.default.compile(e);return function(t){return n.render(t)}}}]),t}();e.default=d},function(t,e,n){var r=n(27);r.Template=n(28).Template,r.template=r.Template,t.exports=r},function(t,e,n){!function(t){var e=/\S/,n=/\"/g,r=/\n/g,i=/\r/g,o=/\\/g,s=/\u2028/,a=/\u2029/;function u(t){return t.trim?t.trim():t.replace(/^\s*|\s*$/g,"")}function c(t,e,n){if(e.charAt(n)!=t.charAt(0))return!1;for(var r=1,i=t.length;r<i;r++)if(e.charAt(n+r)!=t.charAt(r))return!1;return!0}t.tags={"#":1,"^":2,"<":3,$:4,"/":5,"!":6,">":7,"=":8,_v:9,"{":10,"&":11,_t:12},t.scan=function(n,r){var i,o=n.length,s=0,a=null,l=null,h="",f=[],d=!1,p=0,g=0,m="{{",y="}}";function v(){h.length>0&&(f.push({tag:"_t",text:new String(h)}),h="")}function b(n,r){if(v(),n&&function(){for(var n=!0,r=g;r<f.length;r++)if(!(n=t.tags[f[r].tag]<t.tags._v||"_t"==f[r].tag&&null===f[r].text.match(e)))return!1;return n}())for(var i,o=g;o<f.length;o++)f[o].text&&((i=f[o+1])&&">"==i.tag&&(i.indent=f[o].text.toString()),f.splice(o,1));else r||f.push({tag:"\n"});d=!1,g=f.length}function w(t,e){var n="="+y,r=t.indexOf(n,e),i=u(t.substring(t.indexOf("=",e)+1,r)).split(" ");return m=i[0],y=i[i.length-1],r+n.length-1}for(r&&(r=r.split(" "),m=r[0],y=r[1]),p=0;p<o;p++)0==s?c(m,n,p)?(--p,v(),s=1):"\n"==n.charAt(p)?b(d):h+=n.charAt(p):1==s?(p+=m.length-1,"="==(a=(l=t.tags[n.charAt(p+1)])?n.charAt(p+1):"_v")?(p=w(n,p),s=0):(l&&p++,s=2),d=p):c(y,n,p)?(f.push({tag:a,n:u(h),otag:m,ctag:y,i:"/"==a?d-m.length:p+y.length}),h="",p+=y.length-1,s=0,"{"==a&&("}}"==y?p++:"}"===(i=f[f.length-1]).n.substr(i.n.length-1)&&(i.n=i.n.substring(0,i.n.length-1)))):h+=n.charAt(p);return b(d,!0),f};var l={_t:!0,"\n":!0,$:!0,"/":!0};function h(t,e){for(var n=0,r=e.length;n<r;n++)if(e[n].o==t.n)return t.tag="#",!0}function f(t,e,n){for(var r=0,i=n.length;r<i;r++)if(n[r].c==t&&n[r].o==e)return!0}function d(t){var e=[];for(var n in t.partials)e.push('"'+g(n)+'":{name:"'+g(t.partials[n].name)+'", '+d(t.partials[n])+"}");return"partials: {"+e.join(",")+"}, subs: "+function(t){var e=[];for(var n in t)e.push('"'+g(n)+'": function(c,p,t,i) {'+t[n]+"}");return"{ "+e.join(",")+" }"}(t.subs)}t.stringify=function(e,n,r){return"{code: function (c,p,i) { "+t.wrapMain(e.code)+" },"+d(e)+"}"};var p=0;function g(t){return t.replace(o,"\\\\").replace(n,'\\"').replace(r,"\\n").replace(i,"\\r").replace(s,"\\u2028").replace(a,"\\u2029")}function m(t){return~t.indexOf(".")?"d":"f"}function y(t,e){var n="<"+(e.prefix||"")+t.n+p++;return e.partials[n]={name:t.n,partials:{}},e.code+='t.b(t.rp("'+g(n)+'",c,p,"'+(t.indent||"")+'"));',n}function v(t,e){e.code+="t.b(t.t(t."+m(t.n)+'("'+g(t.n)+'",c,p,0)));'}function b(t){return"t.b("+t+");"}t.generate=function(e,n,r){p=0;var i={code:"",subs:{},partials:{}};return t.walk(e,i),r.asString?this.stringify(i,n,r):this.makeTemplate(i,n,r)},t.wrapMain=function(t){return'var t=this;t.b(i=i||"");'+t+"return t.fl();"},t.template=t.Template,t.makeTemplate=function(t,e,n){var r=this.makePartials(t);return r.code=new Function("c","p","i",this.wrapMain(t.code)),new this.template(r,e,this,n)},t.makePartials=function(t){var e,n={subs:{},partials:t.partials,name:t.name};for(e in n.partials)n.partials[e]=this.makePartials(n.partials[e]);for(e in t.subs)n.subs[e]=new Function("c","p","t","i",t.subs[e]);return n},t.codegen={"#":function(e,n){n.code+="if(t.s(t."+m(e.n)+'("'+g(e.n)+'",c,p,1),c,p,0,'+e.i+","+e.end+',"'+e.otag+" "+e.ctag+'")){t.rs(c,p,function(c,p,t){',t.walk(e.nodes,n),n.code+="});c.pop();}"},"^":function(e,n){n.code+="if(!t.s(t."+m(e.n)+'("'+g(e.n)+'",c,p,1),c,p,1,0,0,"")){',t.walk(e.nodes,n),n.code+="};"},">":y,"<":function(e,n){var r={partials:{},code:"",subs:{},inPartial:!0};t.walk(e.nodes,r);var i=n.partials[y(e,n)];i.subs=r.subs,i.partials=r.partials},$:function(e,n){var r={subs:{},code:"",partials:n.partials,prefix:e.n};t.walk(e.nodes,r),n.subs[e.n]=r.code,n.inPartial||(n.code+='t.sub("'+g(e.n)+'",c,p,i);')},"\n":function(t,e){e.code+=b('"\\n"'+(t.last?"":" + i"))},_v:function(t,e){e.code+="t.b(t.v(t."+m(t.n)+'("'+g(t.n)+'",c,p,0)));'},_t:function(t,e){e.code+=b('"'+g(t.text)+'"')},"{":v,"&":v},t.walk=function(e,n){for(var r,i=0,o=e.length;i<o;i++)(r=t.codegen[e[i].tag])&&r(e[i],n);return n},t.parse=function(e,n,r){return function e(n,r,i,o){var s,a=[],u=null,c=null;for(s=i[i.length-1];n.length>0;){if(c=n.shift(),s&&"<"==s.tag&&!(c.tag in l))throw new Error("Illegal content in < super tag.");if(t.tags[c.tag]<=t.tags.$||h(c,o))i.push(c),c.nodes=e(n,c.tag,i,o);else{if("/"==c.tag){if(0===i.length)throw new Error("Closing tag without opener: /"+c.n);if(u=i.pop(),c.n!=u.n&&!f(c.n,u.n,o))throw new Error("Nesting error: "+u.n+" vs. "+c.n);return u.end=c.i,a}"\n"==c.tag&&(c.last=0==n.length||"\n"==n[0].tag)}a.push(c)}if(i.length>0)throw new Error("missing closing tag: "+i.pop().n);return a}(e,0,[],(r=r||{}).sectionTags||[])},t.cache={},t.cacheKey=function(t,e){return[t,!!e.asString,!!e.disableLambda,e.delimiters,!!e.modelGet].join("||")},t.compile=function(e,n){n=n||{};var r=t.cacheKey(e,n),i=this.cache[r];if(i){var o=i.partials;for(var s in o)delete o[s].instance;return i}return i=this.generate(this.parse(this.scan(e,n.delimiters),e,n),e,n),this.cache[r]=i}}(e)},function(t,e,n){!function(t){function e(t,e,n){var r;return e&&"object"==typeof e&&(void 0!==e[t]?r=e[t]:n&&e.get&&"function"==typeof e.get&&(r=e.get(t))),r}t.Template=function(t,e,n,r){t=t||{},this.r=t.code||this.r,this.c=n,this.options=r||{},this.text=e||"",this.partials=t.partials||{},this.subs=t.subs||{},this.buf=""},t.Template.prototype={r:function(t,e,n){return""},v:function(t){return t=u(t),a.test(t)?t.replace(n,"&amp;").replace(r,"&lt;").replace(i,"&gt;").replace(o,"&#39;").replace(s,"&quot;"):t},t:u,render:function(t,e,n){return this.ri([t],e||{},n)},ri:function(t,e,n){return this.r(t,e,n)},ep:function(t,e){var n=this.partials[t],r=e[n.name];if(n.instance&&n.base==r)return n.instance;if("string"==typeof r){if(!this.c)throw new Error("No compiler available.");r=this.c.compile(r,this.options)}if(!r)return null;if(this.partials[t].base=r,n.subs){for(key in e.stackText||(e.stackText={}),n.subs)e.stackText[key]||(e.stackText[key]=void 0!==this.activeSub&&e.stackText[this.activeSub]?e.stackText[this.activeSub]:this.text);r=function(t,e,n,r,i,o){function s(){}function a(){}var u;s.prototype=t,a.prototype=t.subs;var c=new s;for(u in c.subs=new a,c.subsText={},c.buf="",r=r||{},c.stackSubs=r,c.subsText=o,e)r[u]||(r[u]=e[u]);for(u in r)c.subs[u]=r[u];for(u in i=i||{},c.stackPartials=i,n)i[u]||(i[u]=n[u]);for(u in i)c.partials[u]=i[u];return c}(r,n.subs,n.partials,this.stackSubs,this.stackPartials,e.stackText)}return this.partials[t].instance=r,r},rp:function(t,e,n,r){var i=this.ep(t,n);return i?i.ri(e,n,r):""},rs:function(t,e,n){var r=t[t.length-1];if(c(r))for(var i=0;i<r.length;i++)t.push(r[i]),n(t,e,this),t.pop();else n(t,e,this)},s:function(t,e,n,r,i,o,s){var a;return(!c(t)||0!==t.length)&&("function"==typeof t&&(t=this.ms(t,e,n,r,i,o,s)),a=!!t,!r&&a&&e&&e.push("object"==typeof t?t:e[e.length-1]),a)},d:function(t,n,r,i){var o,s=t.split("."),a=this.f(s[0],n,r,i),u=this.options.modelGet,l=null;if("."===t&&c(n[n.length-2]))a=n[n.length-1];else for(var h=1;h<s.length;h++)void 0!==(o=e(s[h],a,u))?(l=a,a=o):a="";return!(i&&!a)&&(i||"function"!=typeof a||(n.push(l),a=this.mv(a,n,r),n.pop()),a)},f:function(t,n,r,i){for(var o=!1,s=!1,a=this.options.modelGet,u=n.length-1;u>=0;u--)if(void 0!==(o=e(t,n[u],a))){s=!0;break}return s?(i||"function"!=typeof o||(o=this.mv(o,n,r)),o):!i&&""},ls:function(t,e,n,r,i){var o=this.options.delimiters;return this.options.delimiters=i,this.b(this.ct(u(t.call(e,r)),e,n)),this.options.delimiters=o,!1},ct:function(t,e,n){if(this.options.disableLambda)throw new Error("Lambda features disabled.");return this.c.compile(t,this.options).render(e,n)},b:function(t){this.buf+=t},fl:function(){var t=this.buf;return this.buf="",t},ms:function(t,e,n,r,i,o,s){var a,u=e[e.length-1],c=t.call(u);return"function"==typeof c?!!r||(a=this.activeSub&&this.subsText&&this.subsText[this.activeSub]?this.subsText[this.activeSub]:this.text,this.ls(c,u,n,a.substring(i,o),s)):c},mv:function(t,e,n){var r=e[e.length-1],i=t.call(r);return"function"==typeof i?this.ct(u(i.call(r)),r,n):i},sub:function(t,e,n,r){var i=this.subs[t];i&&(this.activeSub=t,i(e,n,this,r),this.activeSub=!1)}};var n=/&/g,r=/</g,i=/>/g,o=/\'/g,s=/\"/g,a=/[&<>\"\']/;function u(t){return String(null==t?"":t)}var c=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)}}(e)},function(t,e,n){"use strict";var r=n(30),i=n(41);t.exports=i(r,"(lite) ")},function(t,e,n){t.exports=u;var r=n(5),i=n(31),o=n(32),s=n(38),a=Object({NODE_ENV:"production"}).RESET_APP_DATA_TIMER&&parseInt(Object({NODE_ENV:"production"}).RESET_APP_DATA_TIMER,10)||12e4;function u(t,e,i){var o=n(8)("algoliasearch"),s=n(3),a=n(6),u=n(7),l="Usage: algoliasearch(applicationID, apiKey, opts)";if(!0!==i._allowEmptyCredentials&&!t)throw new r.AlgoliaSearchError("Please provide an application ID. "+l);if(!0!==i._allowEmptyCredentials&&!e)throw new r.AlgoliaSearchError("Please provide an API key. "+l);this.applicationID=t,this.apiKey=e,this.hosts={read:[],write:[]},i=i||{},this._timeouts=i.timeouts||{connect:1e3,read:2e3,write:3e4},i.timeout&&(this._timeouts.connect=this._timeouts.read=this._timeouts.write=i.timeout);var h=i.protocol||"https:";if(/:$/.test(h)||(h+=":"),"http:"!==h&&"https:"!==h)throw new r.AlgoliaSearchError("protocol must be `http:` or `https:` (was `"+i.protocol+"`)");if(this._checkAppIdData(),i.hosts)a(i.hosts)?(this.hosts.read=s(i.hosts),this.hosts.write=s(i.hosts)):(this.hosts.read=s(i.hosts.read),this.hosts.write=s(i.hosts.write));else{var f=u(this._shuffleResult,(function(e){return t+"-"+e+".algolianet.com"})),d=(!1===i.dsn?"":"-dsn")+".algolia.net";this.hosts.read=[this.applicationID+d].concat(f),this.hosts.write=[this.applicationID+".algolia.net"].concat(f)}this.hosts.read=u(this.hosts.read,c(h)),this.hosts.write=u(this.hosts.write,c(h)),this.extraHeaders={},this.cache=i._cache||{},this._ua=i._ua,this._useCache=!(void 0!==i._useCache&&!i._cache)||i._useCache,this._useRequestCache=this._useCache&&i._useRequestCache,this._useFallback=void 0===i.useFallback||i.useFallback,this._setTimeout=i._setTimeout,o("init done, %j",this)}function c(t){return function(e){return t+"//"+e.toLowerCase()}}function l(t){if(void 0===Array.prototype.toJSON)return JSON.stringify(t);var e=Array.prototype.toJSON;delete Array.prototype.toJSON;var n=JSON.stringify(t);return Array.prototype.toJSON=e,n}function h(t){var e={};for(var n in t){var r;Object.prototype.hasOwnProperty.call(t,n)&&(r="x-algolia-api-key"===n||"x-algolia-application-id"===n?"**hidden for security purposes**":t[n],e[n]=r)}return e}u.prototype.initIndex=function(t){return new o(this,t)},u.prototype.setExtraHeader=function(t,e){this.extraHeaders[t.toLowerCase()]=e},u.prototype.getExtraHeader=function(t){return this.extraHeaders[t.toLowerCase()]},u.prototype.unsetExtraHeader=function(t){delete this.extraHeaders[t.toLowerCase()]},u.prototype.addAlgoliaAgent=function(t){-1===this._ua.indexOf(";"+t)&&(this._ua+=";"+t)},u.prototype._jsonRequest=function(t){this._checkAppIdData();var e,o,s,a=n(8)("algoliasearch:"+t.url),u=t.additionalUA||"",c=t.cache,f=this,d=0,p=!1,g=f._useFallback&&f._request.fallback&&t.fallback;this.apiKey.length>500&&void 0!==t.body&&(void 0!==t.body.params||void 0!==t.body.requests)?(t.body.apiKey=this.apiKey,s=this._computeRequestHeaders({additionalUA:u,withApiKey:!1,headers:t.headers})):s=this._computeRequestHeaders({additionalUA:u,headers:t.headers}),void 0!==t.body&&(e=l(t.body)),a("request start");var m=[];function y(t,e,n){return f._useCache&&t&&e&&void 0!==e[n]}function v(e,n){if(y(f._useRequestCache,c,o)&&e.catch((function(){delete c[o]})),"function"!=typeof t.callback)return e.then(n);e.then((function(e){i((function(){t.callback(null,n(e))}),f._setTimeout||setTimeout)}),(function(e){i((function(){t.callback(e)}),f._setTimeout||setTimeout)}))}if(f._useCache&&f._useRequestCache&&(o=t.url),f._useCache&&f._useRequestCache&&e&&(o+="_body_"+e),y(f._useRequestCache,c,o)){a("serving request from cache");var b=c[o];return v("function"!=typeof b.then?f._promise.resolve({responseText:b}):b,(function(t){return JSON.parse(t.responseText)}))}var w=function n(i,v){f._checkAppIdData();var b=new Date;if(f._useCache&&!f._useRequestCache&&(o=t.url),f._useCache&&!f._useRequestCache&&e&&(o+="_body_"+v.body),y(!f._useRequestCache,c,o)){a("serving response from cache");var w=c[o];return f._promise.resolve({body:JSON.parse(w),responseText:w})}if(d>=f.hosts[t.hostType].length)return!g||p?(a("could not get any response"),f._promise.reject(new r.AlgoliaSearchError("Cannot connect to the AlgoliaSearch API. Send an email to [email protected] to report and resolve the issue. Application id was: "+f.applicationID,{debugData:m}))):(a("switching to fallback"),d=0,v.method=t.fallback.method,v.url=t.fallback.url,v.jsonBody=t.fallback.body,v.jsonBody&&(v.body=l(v.jsonBody)),s=f._computeRequestHeaders({additionalUA:u,headers:t.headers}),v.timeouts=f._getTimeoutsForRequest(t.hostType),f._setHostIndexByType(0,t.hostType),p=!0,n(f._request.fallback,v));var _=f._getHostByType(t.hostType),x=_+v.url,S={body:v.body,jsonBody:v.jsonBody,method:v.method,headers:s,timeouts:v.timeouts,debug:a,forceAuthHeaders:v.forceAuthHeaders};return a("method: %s, url: %s, headers: %j, timeouts: %d",S.method,x,S.headers,S.timeouts),i===f._request.fallback&&a("using fallback"),i.call(f,x,S).then((function(t){var n=t&&t.body&&t.body.message&&t.body.status||t.statusCode||t&&t.body&&200;a("received response: statusCode: %s, computed statusCode: %d, headers: %j",t.statusCode,n,t.headers);var i=2===Math.floor(n/100),u=new Date;if(m.push({currentHost:_,headers:h(s),content:e||null,contentLength:void 0!==e?e.length:null,method:v.method,timeouts:v.timeouts,url:v.url,startTime:b,endTime:u,duration:u-b,statusCode:n}),i)return f._useCache&&!f._useRequestCache&&c&&(c[o]=t.responseText),{responseText:t.responseText,body:t.body};if(4!==Math.floor(n/100))return d+=1,C();a("unrecoverable error");var l=new r.AlgoliaSearchError(t.body&&t.body.message,{debugData:m,statusCode:n});return f._promise.reject(l)}),(function(o){a("error: %s, stack: %s",o.message,o.stack);var u=new Date;return m.push({currentHost:_,headers:h(s),content:e||null,contentLength:void 0!==e?e.length:null,method:v.method,timeouts:v.timeouts,url:v.url,startTime:b,endTime:u,duration:u-b}),o instanceof r.AlgoliaSearchError||(o=new r.Unknown(o&&o.message,o)),d+=1,o instanceof r.Unknown||o instanceof r.UnparsableJSON||d>=f.hosts[t.hostType].length&&(p||!g)?(o.debugData=m,f._promise.reject(o)):o instanceof r.RequestTimeout?(a("retrying request with higher timeout"),f._incrementHostIndex(t.hostType),f._incrementTimeoutMultipler(),v.timeouts=f._getTimeoutsForRequest(t.hostType),n(i,v)):C()}));function C(){return a("retrying request"),f._incrementHostIndex(t.hostType),n(i,v)}}(f._request,{url:t.url,method:t.method,body:e,jsonBody:t.body,timeouts:f._getTimeoutsForRequest(t.hostType),forceAuthHeaders:t.forceAuthHeaders});return f._useCache&&f._useRequestCache&&c&&(c[o]=w),v(w,(function(t){return t.body}))},u.prototype._getSearchParams=function(t,e){if(null==t)return e;for(var n in t)null!==n&&void 0!==t[n]&&t.hasOwnProperty(n)&&(e+=""===e?"":"&",e+=n+"="+encodeURIComponent("[object Array]"===Object.prototype.toString.call(t[n])?l(t[n]):t[n]));return e},u.prototype._computeRequestHeaders=function(t){var e=n(2),r={"x-algolia-agent":t.additionalUA?this._ua+";"+t.additionalUA:this._ua,"x-algolia-application-id":this.applicationID};return!1!==t.withApiKey&&(r["x-algolia-api-key"]=this.apiKey),this.userToken&&(r["x-algolia-usertoken"]=this.userToken),this.securityTags&&(r["x-algolia-tagfilters"]=this.securityTags),e(this.extraHeaders,(function(t,e){r[e]=t})),t.headers&&e(t.headers,(function(t,e){r[e]=t})),r},u.prototype.search=function(t,e,r){var i=n(6),o=n(7);if(!i(t))throw new Error("Usage: client.search(arrayOfQueries[, callback])");"function"==typeof e?(r=e,e={}):void 0===e&&(e={});var s=this,a={requests:o(t,(function(t){var e="";return void 0!==t.query&&(e+="query="+encodeURIComponent(t.query)),{indexName:t.indexName,params:s._getSearchParams(t.params,e)}}))},u=o(a.requests,(function(t,e){return e+"="+encodeURIComponent("/1/indexes/"+encodeURIComponent(t.indexName)+"?"+t.params)})).join("&");return void 0!==e.strategy&&(a.strategy=e.strategy),this._jsonRequest({cache:this.cache,method:"POST",url:"/1/indexes/*/queries",body:a,hostType:"read",fallback:{method:"GET",url:"/1/indexes/*",body:{params:u}},callback:r})},u.prototype.searchForFacetValues=function(t){var e=n(6),r=n(7),i="Usage: client.searchForFacetValues([{indexName, params: {facetName, facetQuery, ...params}}, ...queries])";if(!e(t))throw new Error(i);var o=this;return o._promise.all(r(t,(function(t){if(!t||void 0===t.indexName||void 0===t.params.facetName||void 0===t.params.facetQuery)throw new Error(i);var e=n(3),r=n(14),s=t.indexName,a=t.params,u=a.facetName,c=r(e(a),(function(t){return"facetName"===t})),l=o._getSearchParams(c,"");return o._jsonRequest({cache:o.cache,method:"POST",url:"/1/indexes/"+encodeURIComponent(s)+"/facets/"+encodeURIComponent(u)+"/query",hostType:"read",body:{params:l}})})))},u.prototype.setSecurityTags=function(t){if("[object Array]"===Object.prototype.toString.call(t)){for(var e=[],n=0;n<t.length;++n)if("[object Array]"===Object.prototype.toString.call(t[n])){for(var r=[],i=0;i<t[n].length;++i)r.push(t[n][i]);e.push("("+r.join(",")+")")}else e.push(t[n]);t=e.join(",")}this.securityTags=t},u.prototype.setUserToken=function(t){this.userToken=t},u.prototype.clearCache=function(){this.cache={}},u.prototype.setRequestTimeout=function(t){t&&(this._timeouts.connect=this._timeouts.read=this._timeouts.write=t)},u.prototype.setTimeouts=function(t){this._timeouts=t},u.prototype.getTimeouts=function(){return this._timeouts},u.prototype._getAppIdData=function(){var t=s.get(this.applicationID);return null!==t&&this._cacheAppIdData(t),t},u.prototype._setAppIdData=function(t){return t.lastChange=(new Date).getTime(),this._cacheAppIdData(t),s.set(this.applicationID,t)},u.prototype._checkAppIdData=function(){var t=this._getAppIdData(),e=(new Date).getTime();return null===t||e-t.lastChange>a?this._resetInitialAppIdData(t):t},u.prototype._resetInitialAppIdData=function(t){var e=t||{};return e.hostIndexes={read:0,write:0},e.timeoutMultiplier=1,e.shuffleResult=e.shuffleResult||function(t){for(var e,n,r=t.length;0!==r;)n=Math.floor(Math.random()*r),e=t[r-=1],t[r]=t[n],t[n]=e;return t}([1,2,3]),this._setAppIdData(e)},u.prototype._cacheAppIdData=function(t){this._hostIndexes=t.hostIndexes,this._timeoutMultiplier=t.timeoutMultiplier,this._shuffleResult=t.shuffleResult},u.prototype._partialAppIdDataUpdate=function(t){var e=n(2),r=this._getAppIdData();return e(t,(function(t,e){r[e]=t})),this._setAppIdData(r)},u.prototype._getHostByType=function(t){return this.hosts[t][this._getHostIndexByType(t)]},u.prototype._getTimeoutMultiplier=function(){return this._timeoutMultiplier},u.prototype._getHostIndexByType=function(t){return this._hostIndexes[t]},u.prototype._setHostIndexByType=function(t,e){var r=n(3)(this._hostIndexes);return r[e]=t,this._partialAppIdDataUpdate({hostIndexes:r}),t},u.prototype._incrementHostIndex=function(t){return this._setHostIndexByType((this._getHostIndexByType(t)+1)%this.hosts[t].length,t)},u.prototype._incrementTimeoutMultipler=function(){var t=Math.max(this._timeoutMultiplier+1,4);return this._partialAppIdDataUpdate({timeoutMultiplier:t})},u.prototype._getTimeoutsForRequest=function(t){return{connect:this._timeouts.connect*this._timeoutMultiplier,complete:this._timeouts[t]*this._timeoutMultiplier}}},function(t,e){t.exports=function(t,e){e(t,0)}},function(t,e,n){var r=n(13),i=n(33),o=n(34);function s(t,e){this.indexName=e,this.as=t,this.typeAheadArgs=null,this.typeAheadValueOption=null,this.cache={}}t.exports=s,s.prototype.clearCache=function(){this.cache={}},s.prototype.search=r("query"),s.prototype.similarSearch=r("similarQuery"),s.prototype.browse=function(t,e,r){var i,o,s=n(35),a=this;0===arguments.length||1===arguments.length&&"function"==typeof arguments[0]?(i=0,r=arguments[0],t=void 0):"number"==typeof arguments[0]?(i=arguments[0],"number"==typeof arguments[1]?o=arguments[1]:"function"==typeof arguments[1]&&(r=arguments[1],o=void 0),t=void 0,e=void 0):"object"==typeof arguments[0]?("function"==typeof arguments[1]&&(r=arguments[1]),e=arguments[0],t=void 0):"string"==typeof arguments[0]&&"function"==typeof arguments[1]&&(r=arguments[1],e=void 0),e=s({},e||{},{page:i,hitsPerPage:o,query:t});var u=this.as._getSearchParams(e,"");return this.as._jsonRequest({method:"POST",url:"/1/indexes/"+encodeURIComponent(a.indexName)+"/browse",body:{params:u},hostType:"read",callback:r})},s.prototype.browseFrom=function(t,e){return this.as._jsonRequest({method:"POST",url:"/1/indexes/"+encodeURIComponent(this.indexName)+"/browse",body:{cursor:t},hostType:"read",callback:e})},s.prototype.searchForFacetValues=function(t,e){var r=n(3),i=n(14);if(void 0===t.facetName||void 0===t.facetQuery)throw new Error("Usage: index.searchForFacetValues({facetName, facetQuery, ...params}[, callback])");var o=t.facetName,s=i(r(t),(function(t){return"facetName"===t})),a=this.as._getSearchParams(s,"");return this.as._jsonRequest({method:"POST",url:"/1/indexes/"+encodeURIComponent(this.indexName)+"/facets/"+encodeURIComponent(o)+"/query",hostType:"read",body:{params:a},callback:e})},s.prototype.searchFacet=i((function(t,e){return this.searchForFacetValues(t,e)}),o("index.searchFacet(params[, callback])","index.searchForFacetValues(params[, callback])")),s.prototype._search=function(t,e,n,r){return this.as._jsonRequest({cache:this.cache,method:"POST",url:e||"/1/indexes/"+encodeURIComponent(this.indexName)+"/query",body:{params:t},hostType:"read",fallback:{method:"GET",url:"/1/indexes/"+encodeURIComponent(this.indexName),body:{params:t}},callback:n,additionalUA:r})},s.prototype.getObject=function(t,e,n){var r=this;1!==arguments.length&&"function"!=typeof e||(n=e,e=void 0);var i="";if(void 0!==e){i="?attributes=";for(var o=0;o<e.length;++o)0!==o&&(i+=","),i+=e[o]}return this.as._jsonRequest({method:"GET",url:"/1/indexes/"+encodeURIComponent(r.indexName)+"/"+encodeURIComponent(t)+i,hostType:"read",callback:n})},s.prototype.getObjects=function(t,e,r){var i=n(6),o=n(7),s="Usage: index.getObjects(arrayOfObjectIDs[, callback])";if(!i(t))throw new Error(s);var a=this;1!==arguments.length&&"function"!=typeof e||(r=e,e=void 0);var u={requests:o(t,(function(t){var n={indexName:a.indexName,objectID:t};return e&&(n.attributesToRetrieve=e.join(",")),n}))};return this.as._jsonRequest({method:"POST",url:"/1/indexes/*/objects",hostType:"read",body:u,callback:r})},s.prototype.as=null,s.prototype.indexName=null,s.prototype.typeAheadArgs=null,s.prototype.typeAheadValueOption=null},function(t,e){t.exports=function(t,e){var n=!1;return function(){return n||(console.warn(e),n=!0),t.apply(this,arguments)}}},function(t,e){t.exports=function(t,e){var n=t.toLowerCase().replace(/[\.\(\)]/g,"");return"algoliasearch: `"+t+"` was replaced by `"+e+"`. Please see https://github.com/algolia/algoliasearch-client-javascript/wiki/Deprecated#"+n}},function(t,e,n){var r=n(2);t.exports=function t(e){var n=Array.prototype.slice.call(arguments);return r(n,(function(n){for(var r in n)n.hasOwnProperty(r)&&("object"==typeof e[r]&&"object"==typeof n[r]?e[r]=t({},e[r],n[r]):void 0!==n[r]&&(e[r]=n[r]))})),e}},function(t,e,n){"use strict";var r=Object.prototype.hasOwnProperty,i=Object.prototype.toString,o=Array.prototype.slice,s=n(37),a=Object.prototype.propertyIsEnumerable,u=!a.call({toString:null},"toString"),c=a.call((function(){}),"prototype"),l=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],h=function(t){var e=t.constructor;return e&&e.prototype===t},f={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},d=function(){if("undefined"==typeof window)return!1;for(var t in window)try{if(!f["$"+t]&&r.call(window,t)&&null!==window[t]&&"object"==typeof window[t])try{h(window[t])}catch(t){return!0}}catch(t){return!0}return!1}(),p=function(t){var e=null!==t&&"object"==typeof t,n="[object Function]"===i.call(t),o=s(t),a=e&&"[object String]"===i.call(t),f=[];if(!e&&!n&&!o)throw new TypeError("Object.keys called on a non-object");var p=c&&n;if(a&&t.length>0&&!r.call(t,0))for(var g=0;g<t.length;++g)f.push(String(g));if(o&&t.length>0)for(var m=0;m<t.length;++m)f.push(String(m));else for(var y in t)p&&"prototype"===y||!r.call(t,y)||f.push(String(y));if(u)for(var v=function(t){if("undefined"==typeof window||!d)return h(t);try{return h(t)}catch(t){return!1}}(t),b=0;b<l.length;++b)v&&"constructor"===l[b]||!r.call(t,l[b])||f.push(l[b]);return f};p.shim=function(){if(Object.keys){if(!function(){return 2===(Object.keys(arguments)||"").length}(1,2)){var t=Object.keys;Object.keys=function(e){return s(e)?t(o.call(e)):t(e)}}}else Object.keys=p;return Object.keys||p},t.exports=p},function(t,e,n){"use strict";var r=Object.prototype.toString;t.exports=function(t){var e=r.call(t),n="[object Arguments]"===e;return n||(n="[object Array]"!==e&&null!==t&&"object"==typeof t&&"number"==typeof t.length&&t.length>=0&&"[object Function]"===r.call(t.callee)),n}},function(t,e,n){(function(e){var r,i=n(8)("algoliasearch:src/hostIndexState.js"),o={state:{},set:function(t,e){return this.state[t]=e,this.state[t]},get:function(t){return this.state[t]||null}},s={set:function(t,n){o.set(t,n);try{var r=JSON.parse(e.localStorage["algoliasearch-client-js"]);return r[t]=n,e.localStorage["algoliasearch-client-js"]=JSON.stringify(r),r[t]}catch(e){return a(t,e)}},get:function(t){try{return JSON.parse(e.localStorage["algoliasearch-client-js"])[t]||null}catch(e){return a(t,e)}}};function a(t,n){return i("localStorage failed with",n),function(){try{e.localStorage.removeItem("algoliasearch-client-js")}catch(t){}}(),(r=o).get(t)}function u(t,e){return 1===arguments.length?r.get(t):r.set(t,e)}function c(){try{return"localStorage"in e&&null!==e.localStorage&&(e.localStorage["algoliasearch-client-js"]||e.localStorage.setItem("algoliasearch-client-js",JSON.stringify({})),!0)}catch(t){return!1}}r=c()?s:o,t.exports={get:u,set:u,supportsLocalStorage:c}}).call(e,n(4))},function(t,e,n){var r;function i(t){function n(){if(n.enabled){var t=n,i=+new Date,o=i-(r||i);t.diff=o,t.prev=r,t.curr=i,r=i;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=e.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var u=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;u++;var i=e.formatters[r];if("function"==typeof i){var o=s[u];n=i.call(t,o),s.splice(u,1),u--}return n})),e.formatArgs.call(t,s);var c=n.log||e.log||console.log.bind(console);c.apply(t,s)}}return n.namespace=t,n.enabled=e.enabled(t),n.useColors=e.useColors(),n.color=function(t){var n,r=0;for(n in t)r=(r<<5)-r+t.charCodeAt(n),r|=0;return e.colors[Math.abs(r)%e.colors.length]}(t),"function"==typeof e.init&&e.init(n),n}(e=t.exports=i.debug=i.default=i).coerce=function(t){return t instanceof Error?t.stack||t.message:t},e.disable=function(){e.enable("")},e.enable=function(t){e.save(t),e.names=[],e.skips=[];for(var n=("string"==typeof t?t:"").split(/[\s,]+/),r=n.length,i=0;i<r;i++)n[i]&&("-"===(t=n[i].replace(/\*/g,".*?"))[0]?e.skips.push(new RegExp("^"+t.substr(1)+"$")):e.names.push(new RegExp("^"+t+"$")))},e.enabled=function(t){var n,r;for(n=0,r=e.skips.length;n<r;n++)if(e.skips[n].test(t))return!1;for(n=0,r=e.names.length;n<r;n++)if(e.names[n].test(t))return!0;return!1},e.humanize=n(40),e.names=[],e.skips=[],e.formatters={}},function(t,e){var n=1e3,r=6e4,i=60*r,o=24*i;function s(t,e,n){if(!(t<e))return t<1.5*e?Math.floor(t/e)+" "+n:Math.ceil(t/e)+" "+n+"s"}t.exports=function(t,e){e=e||{};var a,u=typeof t;if("string"===u&&t.length>0)return function(t){if(!((t=String(t)).length>100)){var e=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(t);if(e){var s=parseFloat(e[1]);switch((e[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"days":case"day":case"d":return s*o;case"hours":case"hour":case"hrs":case"hr":case"h":return s*i;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}}}(t);if("number"===u&&!1===isNaN(t))return e.long?s(a=t,o,"day")||s(a,i,"hour")||s(a,r,"minute")||s(a,n,"second")||a+" ms":function(t){return t>=o?Math.round(t/o)+"d":t>=i?Math.round(t/i)+"h":t>=r?Math.round(t/r)+"m":t>=n?Math.round(t/n)+"s":t+"ms"}(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))}},function(t,e,n){"use strict";var r=n(42),i=r.Promise||n(43).Promise;t.exports=function(t,e){var o=n(12),s=n(5),a=n(44),u=n(46),c=n(47);function l(t,e,r){return(r=n(3)(r||{}))._ua=r._ua||l.ua,new f(t,e,r)}e=e||"",l.version=n(48),l.ua="Algolia for vanilla JavaScript "+e+l.version,l.initPlaces=c(l),r.__algolia={debug:n(8),algoliasearch:l};var h={hasXMLHttpRequest:"XMLHttpRequest"in r,hasXDomainRequest:"XDomainRequest"in r};function f(){t.apply(this,arguments)}return h.hasXMLHttpRequest&&(h.cors="withCredentials"in new XMLHttpRequest),o(f,t),f.prototype._request=function(t,e){return new i((function(n,r){if(h.cors||h.hasXDomainRequest){t=a(t,e.headers);var i,o,u=e.body,c=h.cors?new XMLHttpRequest:new XDomainRequest,l=!1;i=setTimeout(f,e.timeouts.connect),c.onprogress=function(){l||d()},"onreadystatechange"in c&&(c.onreadystatechange=function(){!l&&c.readyState>1&&d()}),c.onload=function(){if(!o){var t;clearTimeout(i);try{t={body:JSON.parse(c.responseText),responseText:c.responseText,statusCode:c.status,headers:c.getAllResponseHeaders&&c.getAllResponseHeaders()||{}}}catch(e){t=new s.UnparsableJSON({more:c.responseText})}t instanceof s.UnparsableJSON?r(t):n(t)}},c.onerror=function(t){o||(clearTimeout(i),r(new s.Network({more:t})))},c instanceof XMLHttpRequest?(c.open(e.method,t,!0),e.forceAuthHeaders&&(c.setRequestHeader("x-algolia-application-id",e.headers["x-algolia-application-id"]),c.setRequestHeader("x-algolia-api-key",e.headers["x-algolia-api-key"]))):c.open(e.method,t),h.cors&&(u&&("POST"===e.method?c.setRequestHeader("content-type","application/x-www-form-urlencoded"):c.setRequestHeader("content-type","application/json")),c.setRequestHeader("accept","application/json")),u?c.send(u):c.send()}else r(new s.Network("CORS not supported"));function f(){o=!0,c.abort(),r(new s.RequestTimeout)}function d(){l=!0,clearTimeout(i),i=setTimeout(f,e.timeouts.complete)}}))},f.prototype._request.fallback=function(t,e){return t=a(t,e.headers),new i((function(n,r){u(t,e,(function(t,e){t?r(t):n(e)}))}))},f.prototype._promise={reject:function(t){return i.reject(t)},resolve:function(t){return i.resolve(t)},delay:function(t){return new i((function(e){setTimeout(e,t)}))},all:function(t){return i.all(t)}},l}},function(t,e,n){(function(e){var n;n="undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{},t.exports=n}).call(e,n(4))},function(t,e,n){(function(e,n){
/*!
* @overview es6-promise - a tiny implementation of Promises/A+.
* @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
* @license Licensed under MIT license
* See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE
* @version v4.2.4+314e4831
- */var r;r=function(){"use strict";function e(e){return"function"==typeof e}var r=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},i=0,s=void 0,o=void 0,a=function(e,t){p[i]=e,p[i+1]=t,2===(i+=2)&&(o?o(g):w())},c="undefined"!=typeof window?window:void 0,u=c||{},l=u.MutationObserver||u.WebKitMutationObserver,h="undefined"==typeof self&&void 0!==t&&"[object process]"==={}.toString.call(t),d="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function f(){var e=setTimeout;return function(){return e(g,1)}}var p=new Array(1e3);function g(){for(var e=0;e<i;e+=2)(0,p[e])(p[e+1]),p[e]=void 0,p[e+1]=void 0;i=0}var m,v,y,b,w=void 0;function _(e,t){var n=this,r=new this.constructor(S);void 0===r[x]&&j(r);var i=n._state;if(i){var s=arguments[i-1];a((function(){return I(i,r,s,n._result)}))}else M(n,r,e,t);return r}function E(e){if(e&&"object"==typeof e&&e.constructor===this)return e;var t=new this(S);return O(t,e),t}h?w=function(){return t.nextTick(g)}:l?(v=0,y=new l(g),b=document.createTextNode(""),y.observe(b,{characterData:!0}),w=function(){b.data=v=++v%2}):d?((m=new MessageChannel).port1.onmessage=g,w=function(){return m.port2.postMessage(0)}):w=void 0===c?function(){try{var e=Function("return this")().require("vertx");return void 0!==(s=e.runOnLoop||e.runOnContext)?function(){s(g)}:f()}catch(e){return f()}}():f();var x=Math.random().toString(36).substring(2);function S(){}var C={error:null};function A(e){try{return e.then}catch(e){return C.error=e,C}}function N(t,n,r){n.constructor===t.constructor&&r===_&&n.constructor.resolve===E?function(e,t){1===t._state?k(e,t._result):2===t._state?R(e,t._result):M(t,void 0,(function(t){return O(e,t)}),(function(t){return R(e,t)}))}(t,n):r===C?(R(t,C.error),C.error=null):void 0===r?k(t,n):e(r)?function(e,t,n){a((function(e){var r=!1,i=function(e,t,n,r){try{e.call(t,n,r)}catch(e){return e}}(n,t,(function(n){r||(r=!0,t!==n?O(e,n):k(e,n))}),(function(t){r||(r=!0,R(e,t))}),e._label);!r&&i&&(r=!0,R(e,i))}),e)}(t,n,r):k(t,n)}function O(e,t){var n,r;e===t?R(e,new TypeError("You cannot resolve a promise with itself")):(r=typeof(n=t),null===n||"object"!==r&&"function"!==r?k(e,t):N(e,t,A(t)))}function T(e){e._onerror&&e._onerror(e._result),L(e)}function k(e,t){void 0===e._state&&(e._result=t,e._state=1,0!==e._subscribers.length&&a(L,e))}function R(e,t){void 0===e._state&&(e._state=2,e._result=t,a(T,e))}function M(e,t,n,r){var i=e._subscribers,s=i.length;e._onerror=null,i[s]=t,i[s+1]=n,i[s+2]=r,0===s&&e._state&&a(L,e)}function L(e){var t=e._subscribers,n=e._state;if(0!==t.length){for(var r=void 0,i=void 0,s=e._result,o=0;o<t.length;o+=3)r=t[o],i=t[o+n],r?I(n,r,i,s):i(s);e._subscribers.length=0}}function I(t,n,r,i){var s=e(r),o=void 0,a=void 0,c=void 0,u=void 0;if(s){if((o=function(e,t){try{return e(t)}catch(e){return C.error=e,C}}(r,i))===C?(u=!0,a=o.error,o.error=null):c=!0,n===o)return void R(n,new TypeError("A promises callback cannot return that same promise."))}else o=i,c=!0;void 0!==n._state||(s&&c?O(n,o):u?R(n,a):1===t?k(n,o):2===t&&R(n,o))}var D=0;function j(e){e[x]=D++,e._state=void 0,e._result=void 0,e._subscribers=[]}var P=function(){function e(e,t){this._instanceConstructor=e,this.promise=new e(S),this.promise[x]||j(this.promise),r(t)?(this.length=t.length,this._remaining=t.length,this._result=new Array(this.length),0===this.length?k(this.promise,this._result):(this.length=this.length||0,this._enumerate(t),0===this._remaining&&k(this.promise,this._result))):R(this.promise,new Error("Array Methods must be provided an Array"))}return e.prototype._enumerate=function(e){for(var t=0;void 0===this._state&&t<e.length;t++)this._eachEntry(e[t],t)},e.prototype._eachEntry=function(e,t){var n=this._instanceConstructor,r=n.resolve;if(r===E){var i=A(e);if(i===_&&void 0!==e._state)this._settledAt(e._state,t,e._result);else if("function"!=typeof i)this._remaining--,this._result[t]=e;else if(n===$){var s=new n(S);N(s,e,i),this._willSettleAt(s,t)}else this._willSettleAt(new n((function(t){return t(e)})),t)}else this._willSettleAt(r(e),t)},e.prototype._settledAt=function(e,t,n){var r=this.promise;void 0===r._state&&(this._remaining--,2===e?R(r,n):this._result[t]=n),0===this._remaining&&k(r,this._result)},e.prototype._willSettleAt=function(e,t){var n=this;M(e,void 0,(function(e){return n._settledAt(1,t,e)}),(function(e){return n._settledAt(2,t,e)}))},e}(),$=function(){function e(t){this[x]=D++,this._result=this._state=void 0,this._subscribers=[],S!==t&&("function"!=typeof t&&function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof e?function(e,t){try{t((function(t){O(e,t)}),(function(t){R(e,t)}))}catch(t){R(e,t)}}(this,t):function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}())}return e.prototype.catch=function(e){return this.then(null,e)},e.prototype.finally=function(e){var t=this.constructor;return this.then((function(n){return t.resolve(e()).then((function(){return n}))}),(function(n){return t.resolve(e()).then((function(){throw n}))}))},e}();return $.prototype.then=_,$.all=function(e){return new P(this,e).promise},$.race=function(e){var t=this;return r(e)?new t((function(n,r){for(var i=e.length,s=0;s<i;s++)t.resolve(e[s]).then(n,r)})):new t((function(e,t){return t(new TypeError("You must pass an array to race."))}))},$.resolve=E,$.reject=function(e){var t=new this(S);return R(t,e),t},$._setScheduler=function(e){o=e},$._setAsap=function(e){a=e},$._asap=a,$.polyfill=function(){var e=void 0;if(void 0!==n)e=n;else if("undefined"!=typeof self)e=self;else try{e=Function("return this")()}catch(e){throw new Error("polyfill failed because global object is unavailable in this environment")}var t=e.Promise;if(t){var r=null;try{r=Object.prototype.toString.call(t.resolve())}catch(e){}if("[object Promise]"===r&&!t.cast)return}e.Promise=$},$.Promise=$,$},e.exports=r()}).call(t,n(9),n(4))},function(e,t,n){"use strict";e.exports=function(e,t){return/\?/.test(e)?e+="&":e+="?",e+r(t)};var r=n(45)},function(e,t,n){"use strict";var r=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,t,n,a){return t=t||"&",n=n||"=",null===e&&(e=void 0),"object"==typeof e?s(o(e),(function(o){var a=encodeURIComponent(r(o))+n;return i(e[o])?s(e[o],(function(e){return a+encodeURIComponent(r(e))})).join(t):a+encodeURIComponent(r(e[o]))})).join(t):a?encodeURIComponent(r(a))+n+encodeURIComponent(r(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)};function s(e,t){if(e.map)return e.map(t);for(var n=[],r=0;r<e.length;r++)n.push(t(e[r],r));return n}var o=Object.keys||function(e){var t=[];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);return t}},function(e,t,n){"use strict";e.exports=function(e,t,n){if("GET"===t.method){t.debug("JSONP: start");var s=!1,o=!1;i+=1;var a=document.getElementsByTagName("head")[0],c=document.createElement("script"),u="algoliaJSONP_"+i,l=!1;window[u]=function(e){!function(){try{delete window[u],delete window[u+"_loaded"]}catch(e){window[u]=window[u+"_loaded"]=void 0}}(),o?t.debug("JSONP: Late answer, ignoring"):(s=!0,f(),n(null,{body:e,responseText:JSON.stringify(e)}))},e+="&callback="+u,t.jsonBody&&t.jsonBody.params&&(e+="&"+t.jsonBody.params);var h=setTimeout((function(){t.debug("JSONP: Script timeout"),o=!0,f(),n(new r.RequestTimeout)}),t.timeouts.complete);c.onreadystatechange=function(){"loaded"!==this.readyState&&"complete"!==this.readyState||d()},c.onload=d,c.onerror=function(){t.debug("JSONP: Script error"),l||o||(f(),n(new r.JSONPScriptError))},c.async=!0,c.defer=!0,c.src=e,a.appendChild(c)}else n(new Error("Method "+t.method+" "+e+" is not supported by JSONP."));function d(){t.debug("JSONP: success"),l||o||(l=!0,s||(t.debug("JSONP: Fail. Script loaded but did not call the callback"),f(),n(new r.JSONPScriptFail)))}function f(){clearTimeout(h),c.onload=null,c.onreadystatechange=null,c.onerror=null,a.removeChild(c)}};var r=n(5),i=0},function(e,t,n){e.exports=function(e){return function(t,i,s){var o=n(3);(s=s&&o(s)||{}).hosts=s.hosts||["places-dsn.algolia.net","places-1.algolianet.com","places-2.algolianet.com","places-3.algolianet.com"],0!==arguments.length&&"object"!=typeof t&&void 0!==t||(t="",i="",s._allowEmptyCredentials=!0);var a=e(t,i,s),c=a.initIndex("places");return c.search=r("query","/1/places/query"),c.getObject=function(e,t){return this.as._jsonRequest({method:"GET",url:"/1/places/"+encodeURIComponent(e),hostType:"read",callback:t})},c}};var r=n(13)},function(e,t,n){"use strict";e.exports="3.30.0"},function(e,t,n){"use strict";e.exports=n(50)},function(e,t,n){"use strict";var r=n(15);n(1).element=r;var i=n(0);i.isArray=r.isArray,i.isFunction=r.isFunction,i.isObject=r.isPlainObject,i.bind=r.proxy,i.each=function(e,t){r.each(e,(function(e,n){return t(n,e)}))},i.map=r.map,i.mixin=r.extend,i.Event=r.Event;var s=n(51),o=n(16);function a(e,t,n,a){n=i.isArray(n)?n:[].slice.call(arguments,2);var c=r(e).each((function(e,i){var c=r(i),u=new o({el:c}),l=a||new s({input:c,eventBus:u,dropdownMenuContainer:t.dropdownMenuContainer,hint:void 0===t.hint||!!t.hint,minLength:t.minLength,autoselect:t.autoselect,autoselectOnBlur:t.autoselectOnBlur,tabAutocomplete:t.tabAutocomplete,openOnFocus:t.openOnFocus,templates:t.templates,debug:t.debug,clearOnSelected:t.clearOnSelected,cssClasses:t.cssClasses,datasets:n,keyboardShortcuts:t.keyboardShortcuts,appendTo:t.appendTo,autoWidth:t.autoWidth});c.data("aaAutocomplete",l)}));return c.autocomplete={},i.each(["open","close","getVal","setVal","destroy","getWrapper"],(function(e){c.autocomplete[e]=function(){var t,n=arguments;return c.each((function(i,s){var o=r(s).data("aaAutocomplete");t=o[e].apply(o,n)})),t}})),c}a.sources=s.sources,a.escapeHighlightedString=i.escapeHighlightedString;var c="autocomplete"in window,u=window.autocomplete;a.noConflict=function(){return c?window.autocomplete=u:delete window.autocomplete,a},e.exports=a},function(e,t,n){"use strict";var r=n(0),i=n(1),s=n(16),o=n(52),a=n(59),c=n(17),u=n(11);function l(e){var t,n;if((e=e||{}).input||r.error("missing input"),this.isActivated=!1,this.debug=!!e.debug,this.autoselect=!!e.autoselect,this.autoselectOnBlur=!!e.autoselectOnBlur,this.openOnFocus=!!e.openOnFocus,this.minLength=r.isNumber(e.minLength)?e.minLength:1,this.autoWidth=void 0===e.autoWidth||!!e.autoWidth,this.clearOnSelected=!!e.clearOnSelected,this.tabAutocomplete=void 0===e.tabAutocomplete||!!e.tabAutocomplete,e.hint=!!e.hint,e.hint&&e.appendTo)throw new Error("[autocomplete.js] hint and appendTo options can't be used at the same time");this.css=e.css=r.mixin({},u,e.appendTo?u.appendTo:{}),this.cssClasses=e.cssClasses=r.mixin({},u.defaultClasses,e.cssClasses||{}),this.cssClasses.prefix=e.cssClasses.formattedPrefix=r.formatPrefix(this.cssClasses.prefix,this.cssClasses.noPrefix),this.listboxId=e.listboxId=[this.cssClasses.root,"listbox",r.getUniqueId()].join("-");var o=function(e){var t,n,s,o;t=i.element(e.input),n=i.element(c.wrapper.replace("%ROOT%",e.cssClasses.root)).css(e.css.wrapper),e.appendTo||"block"!==t.css("display")||"table"!==t.parent().css("display")||n.css("display","table-cell");var a,u=c.dropdown.replace("%PREFIX%",e.cssClasses.prefix).replace("%DROPDOWN_MENU%",e.cssClasses.dropdownMenu);s=i.element(u).css(e.css.dropdown).attr({role:"listbox",id:e.listboxId}),e.templates&&e.templates.dropdownMenu&&s.html(r.templatify(e.templates.dropdownMenu)()),(o=t.clone().css(e.css.hint).css((a=t,{backgroundAttachment:a.css("background-attachment"),backgroundClip:a.css("background-clip"),backgroundColor:a.css("background-color"),backgroundImage:a.css("background-image"),backgroundOrigin:a.css("background-origin"),backgroundPosition:a.css("background-position"),backgroundRepeat:a.css("background-repeat"),backgroundSize:a.css("background-size")}))).val("").addClass(r.className(e.cssClasses.prefix,e.cssClasses.hint,!0)).removeAttr("id name placeholder required").prop("readonly",!0).attr({"aria-hidden":"true",autocomplete:"off",spellcheck:"false",tabindex:-1}),o.removeData&&o.removeData(),t.data("aaAttrs",{"aria-autocomplete":t.attr("aria-autocomplete"),"aria-expanded":t.attr("aria-expanded"),"aria-owns":t.attr("aria-owns"),autocomplete:t.attr("autocomplete"),dir:t.attr("dir"),role:t.attr("role"),spellcheck:t.attr("spellcheck"),style:t.attr("style"),type:t.attr("type")}),t.addClass(r.className(e.cssClasses.prefix,e.cssClasses.input,!0)).attr({autocomplete:"off",spellcheck:!1,role:"combobox","aria-autocomplete":e.datasets&&e.datasets[0]&&e.datasets[0].displayKey?"both":"list","aria-expanded":"false","aria-label":e.ariaLabel,"aria-owns":e.listboxId}).css(e.hint?e.css.input:e.css.inputWithNoHint);try{t.attr("dir")||t.attr("dir","auto")}catch(e){}return(n=e.appendTo?n.appendTo(i.element(e.appendTo).eq(0)).eq(0):t.wrap(n).parent()).prepend(e.hint?o:null).append(s),{wrapper:n,input:t,hint:o,menu:s}}(e);this.$node=o.wrapper;var a=this.$input=o.input;t=o.menu,n=o.hint,e.dropdownMenuContainer&&i.element(e.dropdownMenuContainer).css("position","relative").append(t.css("top","0")),a.on("blur.aa",(function(e){var n=document.activeElement;r.isMsie()&&(t[0]===n||t[0].contains(n))&&(e.preventDefault(),e.stopImmediatePropagation(),r.defer((function(){a.focus()})))})),t.on("mousedown.aa",(function(e){e.preventDefault()})),this.eventBus=e.eventBus||new s({el:a}),this.dropdown=new l.Dropdown({appendTo:e.appendTo,wrapper:this.$node,menu:t,datasets:e.datasets,templates:e.templates,cssClasses:e.cssClasses,minLength:this.minLength}).onSync("suggestionClicked",this._onSuggestionClicked,this).onSync("cursorMoved",this._onCursorMoved,this).onSync("cursorRemoved",this._onCursorRemoved,this).onSync("opened",this._onOpened,this).onSync("closed",this._onClosed,this).onSync("shown",this._onShown,this).onSync("empty",this._onEmpty,this).onSync("redrawn",this._onRedrawn,this).onAsync("datasetRendered",this._onDatasetRendered,this),this.input=new l.Input({input:a,hint:n}).onSync("focused",this._onFocused,this).onSync("blurred",this._onBlurred,this).onSync("enterKeyed",this._onEnterKeyed,this).onSync("tabKeyed",this._onTabKeyed,this).onSync("escKeyed",this._onEscKeyed,this).onSync("upKeyed",this._onUpKeyed,this).onSync("downKeyed",this._onDownKeyed,this).onSync("leftKeyed",this._onLeftKeyed,this).onSync("rightKeyed",this._onRightKeyed,this).onSync("queryChanged",this._onQueryChanged,this).onSync("whitespaceChanged",this._onWhitespaceChanged,this),this._bindKeyboardShortcuts(e),this._setLanguageDirection()}r.mixin(l.prototype,{_bindKeyboardShortcuts:function(e){if(e.keyboardShortcuts){var t=this.$input,n=[];r.each(e.keyboardShortcuts,(function(e){"string"==typeof e&&(e=e.toUpperCase().charCodeAt(0)),n.push(e)})),i.element(document).keydown((function(e){var r=e.target||e.srcElement,i=r.tagName;if(!r.isContentEditable&&"INPUT"!==i&&"SELECT"!==i&&"TEXTAREA"!==i){var s=e.which||e.keyCode;-1!==n.indexOf(s)&&(t.focus(),e.stopPropagation(),e.preventDefault())}}))}},_onSuggestionClicked:function(e,t){var n;(n=this.dropdown.getDatumForSuggestion(t))&&this._select(n)},_onCursorMoved:function(e,t){var n=this.dropdown.getDatumForCursor(),r=this.dropdown.getCurrentCursor().attr("id");this.input.setActiveDescendant(r),n&&(t&&this.input.setInputValue(n.value,!0),this.eventBus.trigger("cursorchanged",n.raw,n.datasetName))},_onCursorRemoved:function(){this.input.resetInputValue(),this._updateHint(),this.eventBus.trigger("cursorremoved")},_onDatasetRendered:function(){this._updateHint(),this.eventBus.trigger("updated")},_onOpened:function(){this._updateHint(),this.input.expand(),this.eventBus.trigger("opened")},_onEmpty:function(){this.eventBus.trigger("empty")},_onRedrawn:function(){this.$node.css("top","0px"),this.$node.css("left","0px");var e=this.$input[0].getBoundingClientRect();this.autoWidth&&this.$node.css("width",e.width+"px");var t=this.$node[0].getBoundingClientRect(),n=e.bottom-t.top;this.$node.css("top",n+"px");var r=e.left-t.left;this.$node.css("left",r+"px"),this.eventBus.trigger("redrawn")},_onShown:function(){this.eventBus.trigger("shown"),this.autoselect&&this.dropdown.cursorTopSuggestion()},_onClosed:function(){this.input.clearHint(),this.input.removeActiveDescendant(),this.input.collapse(),this.eventBus.trigger("closed")},_onFocused:function(){if(this.isActivated=!0,this.openOnFocus){var e=this.input.getQuery();e.length>=this.minLength?this.dropdown.update(e):this.dropdown.empty(),this.dropdown.open()}},_onBlurred:function(){var e,t;e=this.dropdown.getDatumForCursor(),t=this.dropdown.getDatumForTopSuggestion(),this.debug||(this.autoselectOnBlur&&e?this._select(e):this.autoselectOnBlur&&t?this._select(t):(this.isActivated=!1,this.dropdown.empty(),this.dropdown.close()))},_onEnterKeyed:function(e,t){var n,r;n=this.dropdown.getDatumForCursor(),r=this.dropdown.getDatumForTopSuggestion(),n?(this._select(n),t.preventDefault()):this.autoselect&&r&&(this._select(r),t.preventDefault())},_onTabKeyed:function(e,t){var n;this.tabAutocomplete?(n=this.dropdown.getDatumForCursor())?(this._select(n),t.preventDefault()):this._autocomplete(!0):this.dropdown.close()},_onEscKeyed:function(){this.dropdown.close(),this.input.resetInputValue()},_onUpKeyed:function(){var e=this.input.getQuery();this.dropdown.isEmpty&&e.length>=this.minLength?this.dropdown.update(e):this.dropdown.moveCursorUp(),this.dropdown.open()},_onDownKeyed:function(){var e=this.input.getQuery();this.dropdown.isEmpty&&e.length>=this.minLength?this.dropdown.update(e):this.dropdown.moveCursorDown(),this.dropdown.open()},_onLeftKeyed:function(){"rtl"===this.dir&&this._autocomplete()},_onRightKeyed:function(){"ltr"===this.dir&&this._autocomplete()},_onQueryChanged:function(e,t){this.input.clearHintIfInvalid(),t.length>=this.minLength?this.dropdown.update(t):this.dropdown.empty(),this.dropdown.open(),this._setLanguageDirection()},_onWhitespaceChanged:function(){this._updateHint(),this.dropdown.open()},_setLanguageDirection:function(){var e=this.input.getLanguageDirection();this.dir!==e&&(this.dir=e,this.$node.css("direction",e),this.dropdown.setLanguageDirection(e))},_updateHint:function(){var e,t,n,i,s;(e=this.dropdown.getDatumForTopSuggestion())&&this.dropdown.isVisible()&&!this.input.hasOverflow()?(t=this.input.getInputValue(),n=o.normalizeQuery(t),i=r.escapeRegExChars(n),(s=new RegExp("^(?:"+i+")(.+$)","i").exec(e.value))?this.input.setHint(t+s[1]):this.input.clearHint()):this.input.clearHint()},_autocomplete:function(e){var t,n,r,i;t=this.input.getHint(),n=this.input.getQuery(),r=e||this.input.isCursorAtEnd(),t&&n!==t&&r&&((i=this.dropdown.getDatumForTopSuggestion())&&this.input.setInputValue(i.value),this.eventBus.trigger("autocompleted",i.raw,i.datasetName))},_select:function(e){void 0!==e.value&&this.input.setQuery(e.value),this.clearOnSelected?this.setVal(""):this.input.setInputValue(e.value,!0),this._setLanguageDirection(),!1===this.eventBus.trigger("selected",e.raw,e.datasetName).isDefaultPrevented()&&(this.dropdown.close(),r.defer(r.bind(this.dropdown.empty,this.dropdown)))},open:function(){if(!this.isActivated){var e=this.input.getInputValue();e.length>=this.minLength?this.dropdown.update(e):this.dropdown.empty()}this.dropdown.open()},close:function(){this.dropdown.close()},setVal:function(e){e=r.toStr(e),this.isActivated?this.input.setInputValue(e):(this.input.setQuery(e),this.input.setInputValue(e,!0)),this._setLanguageDirection()},getVal:function(){return this.input.getQuery()},destroy:function(){var e,t,n;this.input.destroy(),this.dropdown.destroy(),e=this.$node,t=this.cssClasses,n=e.find(r.className(t.prefix,t.input)),r.each(n.data("aaAttrs"),(function(e,t){void 0===e?n.removeAttr(t):n.attr(t,e)})),n.detach().removeClass(r.className(t.prefix,t.input,!0)).insertAfter(e),n.removeData&&n.removeData("aaAttrs"),e.remove(),this.$node=null},getWrapper:function(){return this.dropdown.$container[0]}}),l.Dropdown=a,l.Input=o,l.sources=n(61),e.exports=l},function(e,t,n){"use strict";var r;r={9:"tab",27:"esc",37:"left",39:"right",13:"enter",38:"up",40:"down"};var i=n(0),s=n(1),o=n(10);function a(e){var t,n,o,a,c,u=this;(e=e||{}).input||i.error("input is missing"),t=i.bind(this._onBlur,this),n=i.bind(this._onFocus,this),o=i.bind(this._onKeydown,this),a=i.bind(this._onInput,this),this.$hint=s.element(e.hint),this.$input=s.element(e.input).on("blur.aa",t).on("focus.aa",n).on("keydown.aa",o),0===this.$hint.length&&(this.setHint=this.getHint=this.clearHint=this.clearHintIfInvalid=i.noop),i.isMsie()?this.$input.on("keydown.aa keypress.aa cut.aa paste.aa",(function(e){r[e.which||e.keyCode]||i.defer(i.bind(u._onInput,u,e))})):this.$input.on("input.aa",a),this.query=this.$input.val(),this.$overflowHelper=(c=this.$input,s.element('<pre aria-hidden="true"></pre>').css({position:"absolute",visibility:"hidden",whiteSpace:"pre",fontFamily:c.css("font-family"),fontSize:c.css("font-size"),fontStyle:c.css("font-style"),fontVariant:c.css("font-variant"),fontWeight:c.css("font-weight"),wordSpacing:c.css("word-spacing"),letterSpacing:c.css("letter-spacing"),textIndent:c.css("text-indent"),textRendering:c.css("text-rendering"),textTransform:c.css("text-transform")}).insertAfter(c))}function c(e){return e.altKey||e.ctrlKey||e.metaKey||e.shiftKey}a.normalizeQuery=function(e){return(e||"").replace(/^\s*/g,"").replace(/\s{2,}/g," ")},i.mixin(a.prototype,o,{_onBlur:function(){this.resetInputValue(),this.$input.removeAttr("aria-activedescendant"),this.trigger("blurred")},_onFocus:function(){this.trigger("focused")},_onKeydown:function(e){var t=r[e.which||e.keyCode];this._managePreventDefault(t,e),t&&this._shouldTrigger(t,e)&&this.trigger(t+"Keyed",e)},_onInput:function(){this._checkInputValue()},_managePreventDefault:function(e,t){var n,r,i;switch(e){case"tab":r=this.getHint(),i=this.getInputValue(),n=r&&r!==i&&!c(t);break;case"up":case"down":n=!c(t);break;default:n=!1}n&&t.preventDefault()},_shouldTrigger:function(e,t){var n;switch(e){case"tab":n=!c(t);break;default:n=!0}return n},_checkInputValue:function(){var e,t,n,r,i;e=this.getInputValue(),r=e,i=this.query,n=!(!(t=a.normalizeQuery(r)===a.normalizeQuery(i))||!this.query)&&this.query.length!==e.length,this.query=e,t?n&&this.trigger("whitespaceChanged",this.query):this.trigger("queryChanged",this.query)},focus:function(){this.$input.focus()},blur:function(){this.$input.blur()},getQuery:function(){return this.query},setQuery:function(e){this.query=e},getInputValue:function(){return this.$input.val()},setInputValue:function(e,t){void 0===e&&(e=this.query),this.$input.val(e),t?this.clearHint():this._checkInputValue()},expand:function(){this.$input.attr("aria-expanded","true")},collapse:function(){this.$input.attr("aria-expanded","false")},setActiveDescendant:function(e){this.$input.attr("aria-activedescendant",e)},removeActiveDescendant:function(){this.$input.removeAttr("aria-activedescendant")},resetInputValue:function(){this.setInputValue(this.query,!0)},getHint:function(){return this.$hint.val()},setHint:function(e){this.$hint.val(e)},clearHint:function(){this.setHint("")},clearHintIfInvalid:function(){var e,t,n;n=(e=this.getInputValue())!==(t=this.getHint())&&0===t.indexOf(e),""!==e&&n&&!this.hasOverflow()||this.clearHint()},getLanguageDirection:function(){return(this.$input.css("direction")||"ltr").toLowerCase()},hasOverflow:function(){var e=this.$input.width()-2;return this.$overflowHelper.text(this.getInputValue()),this.$overflowHelper.width()>=e},isCursorAtEnd:function(){var e,t,n;return e=this.$input.val().length,t=this.$input[0].selectionStart,i.isNumber(t)?t===e:!document.selection||((n=document.selection.createRange()).moveStart("character",-e),e===n.text.length)},destroy:function(){this.$hint.off(".aa"),this.$input.off(".aa"),this.$hint=this.$input=this.$overflowHelper=null}}),e.exports=a},function(e,t,n){"use strict";var r,i,s,o=[n(54),n(55),n(56),n(57),n(58)],a=-1,c=[],u=!1;function l(){r&&i&&(r=!1,i.length?c=i.concat(c):a=-1,c.length&&h())}function h(){if(!r){u=!1,r=!0;for(var e=c.length,t=setTimeout(l);e;){for(i=c,c=[];i&&++a<e;)i[a].run();a=-1,e=c.length}i=null,a=-1,r=!1,clearTimeout(t)}}for(var d=-1,f=o.length;++d<f;)if(o[d]&&o[d].test&&o[d].test()){s=o[d].install(h);break}function p(e,t){this.fun=e,this.array=t}p.prototype.run=function(){var e=this.fun,t=this.array;switch(t.length){case 0:return e();case 1:return e(t[0]);case 2:return e(t[0],t[1]);case 3:return e(t[0],t[1],t[2]);default:return e.apply(null,t)}},e.exports=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];c.push(new p(e,t)),u||r||(u=!0,s())}},function(e,t,n){"use strict";(function(e){t.test=function(){return void 0!==e&&!e.browser},t.install=function(t){return function(){e.nextTick(t)}}}).call(t,n(9))},function(e,t,n){"use strict";(function(e){var n=e.MutationObserver||e.WebKitMutationObserver;t.test=function(){return n},t.install=function(t){var r=0,i=new n(t),s=e.document.createTextNode("");return i.observe(s,{characterData:!0}),function(){s.data=r=++r%2}}}).call(t,n(4))},function(e,t,n){"use strict";(function(e){t.test=function(){return!e.setImmediate&&void 0!==e.MessageChannel},t.install=function(t){var n=new e.MessageChannel;return n.port1.onmessage=t,function(){n.port2.postMessage(0)}}}).call(t,n(4))},function(e,t,n){"use strict";(function(e){t.test=function(){return"document"in e&&"onreadystatechange"in e.document.createElement("script")},t.install=function(t){return function(){var n=e.document.createElement("script");return n.onreadystatechange=function(){t(),n.onreadystatechange=null,n.parentNode.removeChild(n),n=null},e.document.documentElement.appendChild(n),t}}}).call(t,n(4))},function(e,t,n){"use strict";t.test=function(){return!0},t.install=function(e){return function(){setTimeout(e,0)}}},function(e,t,n){"use strict";var r=n(0),i=n(1),s=n(10),o=n(60),a=n(11);function c(e){var t,n,s,o=this;(e=e||{}).menu||r.error("menu is required"),r.isArray(e.datasets)||r.isObject(e.datasets)||r.error("1 or more datasets required"),e.datasets||r.error("datasets is required"),this.isOpen=!1,this.isEmpty=!0,this.minLength=e.minLength||0,this.templates={},this.appendTo=e.appendTo||!1,this.css=r.mixin({},a,e.appendTo?a.appendTo:{}),this.cssClasses=e.cssClasses=r.mixin({},a.defaultClasses,e.cssClasses||{}),this.cssClasses.prefix=e.cssClasses.formattedPrefix||r.formatPrefix(this.cssClasses.prefix,this.cssClasses.noPrefix),t=r.bind(this._onSuggestionClick,this),n=r.bind(this._onSuggestionMouseEnter,this),s=r.bind(this._onSuggestionMouseLeave,this);var u=r.className(this.cssClasses.prefix,this.cssClasses.suggestion);this.$menu=i.element(e.menu).on("mouseenter.aa",u,n).on("mouseleave.aa",u,s).on("click.aa",u,t),this.$container=e.appendTo?e.wrapper:this.$menu,e.templates&&e.templates.header&&(this.templates.header=r.templatify(e.templates.header),this.$menu.prepend(this.templates.header())),e.templates&&e.templates.empty&&(this.templates.empty=r.templatify(e.templates.empty),this.$empty=i.element('<div class="'+r.className(this.cssClasses.prefix,this.cssClasses.empty,!0)+'"></div>'),this.$menu.append(this.$empty),this.$empty.hide()),this.datasets=r.map(e.datasets,(function(t){return function(e,t,n){return new c.Dataset(r.mixin({$menu:e,cssClasses:n},t))}(o.$menu,t,e.cssClasses)})),r.each(this.datasets,(function(e){var t=e.getRoot();t&&0===t.parent().length&&o.$menu.append(t),e.onSync("rendered",o._onRendered,o)})),e.templates&&e.templates.footer&&(this.templates.footer=r.templatify(e.templates.footer),this.$menu.append(this.templates.footer()));var l=this;i.element(window).resize((function(){l._redraw()}))}r.mixin(c.prototype,s,{_onSuggestionClick:function(e){this.trigger("suggestionClicked",i.element(e.currentTarget))},_onSuggestionMouseEnter:function(e){var t=i.element(e.currentTarget);if(!t.hasClass(r.className(this.cssClasses.prefix,this.cssClasses.cursor,!0))){this._removeCursor();var n=this;setTimeout((function(){n._setCursor(t,!1)}),0)}},_onSuggestionMouseLeave:function(e){e.relatedTarget&&i.element(e.relatedTarget).closest("."+r.className(this.cssClasses.prefix,this.cssClasses.cursor,!0)).length>0||(this._removeCursor(),this.trigger("cursorRemoved"))},_onRendered:function(e,t){if(this.isEmpty=r.every(this.datasets,(function(e){return e.isEmpty()})),this.isEmpty)if(t.length>=this.minLength&&this.trigger("empty"),this.$empty)if(t.length<this.minLength)this._hide();else{var n=this.templates.empty({query:this.datasets[0]&&this.datasets[0].query});this.$empty.html(n),this.$empty.show(),this._show()}else r.any(this.datasets,(function(e){return e.templates&&e.templates.empty}))?t.length<this.minLength?this._hide():this._show():this._hide();else this.isOpen&&(this.$empty&&(this.$empty.empty(),this.$empty.hide()),t.length>=this.minLength?this._show():this._hide());this.trigger("datasetRendered")},_hide:function(){this.$container.hide()},_show:function(){this.$container.css("display","block"),this._redraw(),this.trigger("shown")},_redraw:function(){this.isOpen&&this.appendTo&&this.trigger("redrawn")},_getSuggestions:function(){return this.$menu.find(r.className(this.cssClasses.prefix,this.cssClasses.suggestion))},_getCursor:function(){return this.$menu.find(r.className(this.cssClasses.prefix,this.cssClasses.cursor)).first()},_setCursor:function(e,t){e.first().addClass(r.className(this.cssClasses.prefix,this.cssClasses.cursor,!0)).attr("aria-selected","true"),this.trigger("cursorMoved",t)},_removeCursor:function(){this._getCursor().removeClass(r.className(this.cssClasses.prefix,this.cssClasses.cursor,!0)).removeAttr("aria-selected")},_moveCursor:function(e){var t,n,r,i;this.isOpen&&(n=this._getCursor(),t=this._getSuggestions(),this._removeCursor(),-1!=(r=((r=t.index(n)+e)+1)%(t.length+1)-1)?(r<-1&&(r=t.length-1),this._setCursor(i=t.eq(r),!0),this._ensureVisible(i)):this.trigger("cursorRemoved"))},_ensureVisible:function(e){var t,n,r,i;n=(t=e.position().top)+e.height()+parseInt(e.css("margin-top"),10)+parseInt(e.css("margin-bottom"),10),r=this.$menu.scrollTop(),i=this.$menu.height()+parseInt(this.$menu.css("padding-top"),10)+parseInt(this.$menu.css("padding-bottom"),10),t<0?this.$menu.scrollTop(r+t):i<n&&this.$menu.scrollTop(r+(n-i))},close:function(){this.isOpen&&(this.isOpen=!1,this._removeCursor(),this._hide(),this.trigger("closed"))},open:function(){this.isOpen||(this.isOpen=!0,this.isEmpty||this._show(),this.trigger("opened"))},setLanguageDirection:function(e){this.$menu.css("ltr"===e?this.css.ltr:this.css.rtl)},moveCursorUp:function(){this._moveCursor(-1)},moveCursorDown:function(){this._moveCursor(1)},getDatumForSuggestion:function(e){var t=null;return e.length&&(t={raw:o.extractDatum(e),value:o.extractValue(e),datasetName:o.extractDatasetName(e)}),t},getCurrentCursor:function(){return this._getCursor().first()},getDatumForCursor:function(){return this.getDatumForSuggestion(this._getCursor().first())},getDatumForTopSuggestion:function(){return this.getDatumForSuggestion(this._getSuggestions().first())},cursorTopSuggestion:function(){this._setCursor(this._getSuggestions().first(),!1)},update:function(e){r.each(this.datasets,(function(t){t.update(e)}))},empty:function(){r.each(this.datasets,(function(e){e.clear()})),this.isEmpty=!0},isVisible:function(){return this.isOpen&&!this.isEmpty},destroy:function(){this.$menu.off(".aa"),this.$menu=null,r.each(this.datasets,(function(e){e.destroy()}))}}),c.Dataset=o,e.exports=c},function(e,t,n){"use strict";var r=n(0),i=n(1),s=n(17),o=n(11),a=n(10);function c(e){var t,n,a,c;(e=e||{}).templates=e.templates||{},e.source||r.error("missing source"),e.name&&(t=e.name,!/^[_a-zA-Z0-9-]+$/.test(t))&&r.error("invalid dataset name: "+e.name),this.query=null,this._isEmpty=!0,this.highlight=!!e.highlight,this.name=void 0===e.name||null===e.name?r.getUniqueId():e.name,this.source=e.source,this.displayFn=(n=(n=e.display||e.displayKey)||"value",r.isFunction(n)?n:function(e){return e[n]}),this.debounce=e.debounce,this.cache=!1!==e.cache,this.templates=(a=e.templates,c=this.displayFn,{empty:a.empty&&r.templatify(a.empty),header:a.header&&r.templatify(a.header),footer:a.footer&&r.templatify(a.footer),suggestion:a.suggestion||function(e){return"<p>"+c(e)+"</p>"}}),this.css=r.mixin({},o,e.appendTo?o.appendTo:{}),this.cssClasses=e.cssClasses=r.mixin({},o.defaultClasses,e.cssClasses||{}),this.cssClasses.prefix=e.cssClasses.formattedPrefix||r.formatPrefix(this.cssClasses.prefix,this.cssClasses.noPrefix);var u=r.className(this.cssClasses.prefix,this.cssClasses.dataset);this.$el=e.$menu&&e.$menu.find(u+"-"+this.name).length>0?i.element(e.$menu.find(u+"-"+this.name)[0]):i.element(s.dataset.replace("%CLASS%",this.name).replace("%PREFIX%",this.cssClasses.prefix).replace("%DATASET%",this.cssClasses.dataset)),this.$menu=e.$menu,this.clearCachedSuggestions()}c.extractDatasetName=function(e){return i.element(e).data("aaDataset")},c.extractValue=function(e){return i.element(e).data("aaValue")},c.extractDatum=function(e){var t=i.element(e).data("aaDatum");return"string"==typeof t&&(t=JSON.parse(t)),t},r.mixin(c.prototype,a,{_render:function(e,t){if(this.$el){var n,o=this,a=[].slice.call(arguments,2);if(this.$el.empty(),n=t&&t.length,this._isEmpty=!n,!n&&this.templates.empty)this.$el.html(c.apply(this,a)).prepend(o.templates.header?l.apply(this,a):null).append(o.templates.footer?h.apply(this,a):null);else if(n)this.$el.html(u.apply(this,a)).prepend(o.templates.header?l.apply(this,a):null).append(o.templates.footer?h.apply(this,a):null);else if(t&&!Array.isArray(t))throw new TypeError("suggestions must be an array");this.$menu&&this.$menu.addClass(this.cssClasses.prefix+(n?"with":"without")+"-"+this.name).removeClass(this.cssClasses.prefix+(n?"without":"with")+"-"+this.name),this.trigger("rendered",e)}function c(){var t=[].slice.call(arguments,0);return t=[{query:e,isEmpty:!0}].concat(t),o.templates.empty.apply(this,t)}function u(){var e,n,a=[].slice.call(arguments,0),c=this,u=s.suggestions.replace("%PREFIX%",this.cssClasses.prefix).replace("%SUGGESTIONS%",this.cssClasses.suggestions);return e=i.element(u).css(this.css.suggestions),n=r.map(t,l),e.append.apply(e,n),e;function l(e){var t,n=s.suggestion.replace("%PREFIX%",c.cssClasses.prefix).replace("%SUGGESTION%",c.cssClasses.suggestion);return(t=i.element(n).attr({role:"option",id:["option",Math.floor(1e8*Math.random())].join("-")}).append(o.templates.suggestion.apply(this,[e].concat(a)))).data("aaDataset",o.name),t.data("aaValue",o.displayFn(e)||void 0),t.data("aaDatum",JSON.stringify(e)),t.children().each((function(){i.element(this).css(c.css.suggestionChild)})),t}}function l(){var t=[].slice.call(arguments,0);return t=[{query:e,isEmpty:!n}].concat(t),o.templates.header.apply(this,t)}function h(){var t=[].slice.call(arguments,0);return t=[{query:e,isEmpty:!n}].concat(t),o.templates.footer.apply(this,t)}},getRoot:function(){return this.$el},update:function(e){function t(t){if(!this.canceled&&e===this.query){var n=[].slice.call(arguments,1);this.cacheSuggestions(e,t,n),this._render.apply(this,[e,t].concat(n))}}if(this.query=e,this.canceled=!1,this.shouldFetchFromCache(e))t.apply(this,[this.cachedSuggestions].concat(this.cachedRenderExtraArgs));else{var n=this,r=function(){n.canceled||n.source(e,t.bind(n))};this.debounce?(clearTimeout(this.debounceTimeout),this.debounceTimeout=setTimeout((function(){n.debounceTimeout=null,r()}),this.debounce)):r()}},cacheSuggestions:function(e,t,n){this.cachedQuery=e,this.cachedSuggestions=t,this.cachedRenderExtraArgs=n},shouldFetchFromCache:function(e){return this.cache&&this.cachedQuery===e&&this.cachedSuggestions&&this.cachedSuggestions.length},clearCachedSuggestions:function(){delete this.cachedQuery,delete this.cachedSuggestions,delete this.cachedRenderExtraArgs},cancel:function(){this.canceled=!0},clear:function(){this.cancel(),this.$el.empty(),this.trigger("rendered","")},isEmpty:function(){return this._isEmpty},destroy:function(){this.clearCachedSuggestions(),this.$el=null}}),e.exports=c},function(e,t,n){"use strict";e.exports={hits:n(62),popularIn:n(63)}},function(e,t,n){"use strict";var r=n(0),i=n(18),s=n(19);e.exports=function(e,t){var n=s(e.as._ua);return n&&n[0]>=3&&n[1]>20&&((t=t||{}).additionalUA="autocomplete.js "+i),function(n,i){e.search(n,t,(function(e,t){e?r.error(e.message):i(t.hits,t)}))}}},function(e,t,n){"use strict";var r=n(0),i=n(18),s=n(19);e.exports=function(e,t,n,o){var a=s(e.as._ua);if(a&&a[0]>=3&&a[1]>20&&((t=t||{}).additionalUA="autocomplete.js "+i),!n.source)return r.error("Missing 'source' key");var c=r.isFunction(n.source)?n.source:function(e){return e[n.source]};if(!n.index)return r.error("Missing 'index' key");var u=n.index;return o=o||{},function(a,l){e.search(a,t,(function(e,a){if(e)r.error(e.message);else{if(a.hits.length>0){var h=a.hits[0],d=r.mixin({hitsPerPage:0},n);delete d.source,delete d.index;var f=s(u.as._ua);return f&&f[0]>=3&&f[1]>20&&(t.additionalUA="autocomplete.js "+i),void u.search(c(h),d,(function(e,t){if(e)r.error(e.message);else{var n=[];if(o.includeAll){var i=o.allTitle||"All departments";n.push(r.mixin({facet:{value:i,count:t.nbHits}},r.cloneDeep(h)))}r.each(t.facets,(function(e,t){r.each(e,(function(e,i){n.push(r.mixin({facet:{facet:t,value:i,count:e}},r.cloneDeep(h)))}))}));for(var s=1;s<a.hits.length;++s)n.push(a.hits[s]);l(n,a)}}))}l([])}}))}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r="algolia-docsearch-suggestion",i={suggestion:'\n <a class="'+r+"\n {{#isCategoryHeader}}"+r+"__main{{/isCategoryHeader}}\n {{#isSubCategoryHeader}}"+r+'__secondary{{/isSubCategoryHeader}}\n "\n aria-label="Link to the result"\n href="{{{url}}}"\n >\n <div class="'+r+'--category-header">\n <span class="'+r+'--category-header-lvl0">{{{category}}}</span>\n </div>\n <div class="'+r+'--wrapper">\n <div class="'+r+'--subcategory-column">\n <span class="'+r+'--subcategory-column-text">{{{subcategory}}}</span>\n </div>\n {{#isTextOrSubcategoryNonEmpty}}\n <div class="'+r+'--content">\n <div class="'+r+'--subcategory-inline">{{{subcategory}}}</div>\n <div class="'+r+'--title">{{{title}}}</div>\n {{#text}}<div class="'+r+'--text">{{{text}}}</div>{{/text}}\n </div>\n {{/isTextOrSubcategoryNonEmpty}}\n </div>\n </a>\n ',suggestionSimple:'\n <div class="'+r+"\n {{#isCategoryHeader}}"+r+"__main{{/isCategoryHeader}}\n {{#isSubCategoryHeader}}"+r+'__secondary{{/isSubCategoryHeader}}\n suggestion-layout-simple\n ">\n <div class="'+r+'--category-header">\n {{^isLvl0}}\n <span class="'+r+"--category-header-lvl0 "+r+'--category-header-item">{{{category}}}</span>\n {{^isLvl1}}\n {{^isLvl1EmptyOrDuplicate}}\n <span class="'+r+"--category-header-lvl1 "+r+'--category-header-item">\n {{{subcategory}}}\n </span>\n {{/isLvl1EmptyOrDuplicate}}\n {{/isLvl1}}\n {{/isLvl0}}\n <div class="'+r+"--title "+r+'--category-header-item">\n {{#isLvl2}}\n {{{title}}}\n {{/isLvl2}}\n {{#isLvl1}}\n {{{subcategory}}}\n {{/isLvl1}}\n {{#isLvl0}}\n {{{category}}}\n {{/isLvl0}}\n </div>\n </div>\n <div class="'+r+'--wrapper">\n {{#text}}\n <div class="'+r+'--content">\n <div class="'+r+'--text">{{{text}}}</div>\n </div>\n {{/text}}\n </div>\n </div>\n ',footer:'\n <div class="algolia-docsearch-footer">\n Search by <a class="algolia-docsearch-footer--logo" href="https://www.algolia.com/docsearch">Algolia</a>\n </div>\n ',empty:'\n <div class="'+r+'">\n <div class="'+r+'--wrapper">\n <div class="'+r+"--content "+r+'--no-results">\n <div class="'+r+'--title">\n <div class="'+r+'--text">\n No results found for query <b>"{{query}}"</b>\n </div>\n </div>\n </div>\n </div>\n </div>\n ',searchBox:'\n <form novalidate="novalidate" onsubmit="return false;" class="searchbox">\n <div role="search" class="searchbox__wrapper">\n <input id="docsearch" type="search" name="search" placeholder="Search the docs" autocomplete="off" required="required" class="searchbox__input"/>\n <button type="submit" title="Submit your search query." class="searchbox__submit" >\n <svg width=12 height=12 role="img" aria-label="Search">\n <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#sbx-icon-search-13"></use>\n </svg>\n </button>\n <button type="reset" title="Clear the search query." class="searchbox__reset hide">\n <svg width=12 height=12 role="img" aria-label="Reset">\n <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#sbx-icon-clear-3"></use>\n </svg>\n </button>\n </div>\n</form>\n\n<div class="svg-icons" style="height: 0; width: 0; position: absolute; visibility: hidden">\n <svg xmlns="http://www.w3.org/2000/svg">\n <symbol id="sbx-icon-clear-3" viewBox="0 0 40 40"><path d="M16.228 20L1.886 5.657 0 3.772 3.772 0l1.885 1.886L20 16.228 34.343 1.886 36.228 0 40 3.772l-1.886 1.885L23.772 20l14.342 14.343L40 36.228 36.228 40l-1.885-1.886L20 23.772 5.657 38.114 3.772 40 0 36.228l1.886-1.885L16.228 20z" fill-rule="evenodd"></symbol>\n <symbol id="sbx-icon-search-13" viewBox="0 0 40 40"><path d="M26.806 29.012a16.312 16.312 0 0 1-10.427 3.746C7.332 32.758 0 25.425 0 16.378 0 7.334 7.333 0 16.38 0c9.045 0 16.378 7.333 16.378 16.38 0 3.96-1.406 7.593-3.746 10.426L39.547 37.34c.607.608.61 1.59-.004 2.203a1.56 1.56 0 0 1-2.202.004L26.807 29.012zm-10.427.627c7.322 0 13.26-5.938 13.26-13.26 0-7.324-5.938-13.26-13.26-13.26-7.324 0-13.26 5.936-13.26 13.26 0 7.322 5.936 13.26 13.26 13.26z" fill-rule="evenodd"></symbol>\n </svg>\n</div>\n '};t.default=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=n(20),o=(r=s)&&r.__esModule?r:{default:r},a={mergeKeyWithParent:function(e,t){if(void 0===e[t])return e;if("object"!==i(e[t]))return e;var n=o.default.extend({},e,e[t]);return delete n[t],n},groupBy:function(e,t){var n={};return o.default.each(e,(function(e,r){if(void 0===r[t])throw new Error("[groupBy]: Object has no key "+t);var i=r[t];"string"==typeof i&&(i=i.toLowerCase()),Object.prototype.hasOwnProperty.call(n,i)||(n[i]=[]),n[i].push(r)})),n},values:function(e){return Object.keys(e).map((function(t){return e[t]}))},flatten:function(e){var t=[];return e.forEach((function(e){Array.isArray(e)?e.forEach((function(e){t.push(e)})):t.push(e)})),t},flattenAndFlagFirst:function(e,t){var n=this.values(e).map((function(e){return e.map((function(e,n){return e[t]=0===n,e}))}));return this.flatten(n)},compact:function(e){var t=[];return e.forEach((function(e){e&&t.push(e)})),t},getHighlightedValue:function(e,t){return e._highlightResult&&e._highlightResult.hierarchy_camel&&e._highlightResult.hierarchy_camel[t]&&e._highlightResult.hierarchy_camel[t].matchLevel&&"none"!==e._highlightResult.hierarchy_camel[t].matchLevel&&e._highlightResult.hierarchy_camel[t].value?e._highlightResult.hierarchy_camel[t].value:e._highlightResult&&e._highlightResult&&e._highlightResult[t]&&e._highlightResult[t].value?e._highlightResult[t].value:e[t]},getSnippetedValue:function(e,t){if(!e._snippetResult||!e._snippetResult[t]||!e._snippetResult[t].value)return e[t];var n=e._snippetResult[t].value;return n[0]!==n[0].toUpperCase()&&(n="…"+n),-1===[".","!","?"].indexOf(n[n.length-1])&&(n+="…"),n},deepClone:function(e){return JSON.parse(JSON.stringify(e))}};t.default=a}])},e.exports=r()},function(e,t,n){var r=n(10);r.registerLanguage("bash",n(11)),r.registerLanguage("css",n(12)),r.registerLanguage("markdown",n(13)),r.registerLanguage("diff",n(14)),r.registerLanguage("javascript",n(15)),r.registerLanguage("json",n(16)),r.registerLanguage("yaml",n(17)),r.registerLanguage("xml",n(18)),r.registerLanguage("html",n(19)),r.registerLanguage("go",(function(e){var t={keyword:"code output note warning break default func interface select case map struct chan else goto package switch const fallthrough if range end type continue for import return var go defer bool byte complex64 complex128 float32 float64 int8 int16 int32 int64 string uint8 uint16 uint32 uint64 int uint uintptr rune id autoplay Get",literal:"file download copy true false iota nil Pages with",built_in:"append cap close complex highlight copy imag len make new panic print println real recover delete Site Data tweet youtube ref relref vimeo instagram gist figure innershortcode"};return{aliases:["golang","hugo"],k:t,i:"</",c:[e.CLCM,e.CBCM,{cN:"string",v:[e.QSM,{b:"'",e:"[^\\\\]'"},{b:"`",e:"`"}]},{cN:"number",v:[{b:e.CNR+"[dflsi]",r:1},e.CNM]},{b:/:=/},{cN:"function",bK:"func",e:/\s*\{/,eE:!0,c:[e.TM,{cN:"params",b:/\(/,e:/\)/,k:t,i:/["']/}]}]}})),r.initHighlightingOnLoad()},function(e,t,n){!function(e){"object"==typeof window&&window||"object"==typeof self&&self;(function(e){var t=[],n=Object.keys,r={},i={},s=/^(no-?highlight|plain|text)$/i,o=/\blang(?:uage)?-([\w-]+)\b/i,a=/((^(<[^>]+>|\t|)+|(?:\n)))/gm,c={classPrefix:"hljs-",tabReplace:null,useBR:!1,languages:void 0};function u(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function l(e){return e.nodeName.toLowerCase()}function h(e,t){var n=e&&e.exec(t);return n&&0===n.index}function d(e){return s.test(e)}function f(e){var t,n={},r=Array.prototype.slice.call(arguments,1);for(t in e)n[t]=e[t];return r.forEach((function(e){for(t in e)n[t]=e[t]})),n}function p(e){var t=[];return function e(n,r){for(var i=n.firstChild;i;i=i.nextSibling)3===i.nodeType?r+=i.nodeValue.length:1===i.nodeType&&(t.push({event:"start",offset:r,node:i}),r=e(i,r),l(i).match(/br|hr|img|input/)||t.push({event:"stop",offset:r,node:i}));return r}(e,0),t}function g(e){function t(e){return e&&e.source||e}function r(n,r){return new RegExp(t(n),"m"+(e.case_insensitive?"i":"")+(r?"g":""))}!function i(s,o){if(!s.compiled){if(s.compiled=!0,s.keywords=s.keywords||s.beginKeywords,s.keywords){var a={},c=function(t,n){e.case_insensitive&&(n=n.toLowerCase()),n.split(" ").forEach((function(e){var n=e.split("|");a[n[0]]=[t,n[1]?Number(n[1]):1]}))};"string"==typeof s.keywords?c("keyword",s.keywords):n(s.keywords).forEach((function(e){c(e,s.keywords[e])})),s.keywords=a}s.lexemesRe=r(s.lexemes||/\w+/,!0),o&&(s.beginKeywords&&(s.begin="\\b("+s.beginKeywords.split(" ").join("|")+")\\b"),s.begin||(s.begin=/\B|\b/),s.beginRe=r(s.begin),s.endSameAsBegin&&(s.end=s.begin),s.end||s.endsWithParent||(s.end=/\B|\b/),s.end&&(s.endRe=r(s.end)),s.terminator_end=t(s.end)||"",s.endsWithParent&&o.terminator_end&&(s.terminator_end+=(s.end?"|":"")+o.terminator_end)),s.illegal&&(s.illegalRe=r(s.illegal)),null==s.relevance&&(s.relevance=1),s.contains||(s.contains=[]),s.contains=Array.prototype.concat.apply([],s.contains.map((function(e){return function(e){return e.variants&&!e.cached_variants&&(e.cached_variants=e.variants.map((function(t){return f(e,{variants:null},t)}))),e.cached_variants||e.endsWithParent&&[f(e)]||[e]}("self"===e?s:e)}))),s.contains.forEach((function(e){i(e,s)})),s.starts&&i(s.starts,o);var u=s.contains.map((function(e){return e.beginKeywords?"\\.?("+e.begin+")\\.?":e.begin})).concat([s.terminator_end,s.illegal]).map(t).filter(Boolean);s.terminators=u.length?r(u.join("|"),!0):{exec:function(){return null}}}}(e)}function m(e,t,n,i){function s(e){return new RegExp(e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"),"m")}function o(e,t){var n=p.case_insensitive?t[0].toLowerCase():t[0];return e.keywords.hasOwnProperty(n)&&e.keywords[n]}function a(e,t,n,r){var i='<span class="'+(r?"":c.classPrefix);return(i+=e+'">')+t+(n?"":"</span>")}function l(){E+=null!=b.subLanguage?function(){var e="string"==typeof b.subLanguage;if(e&&!r[b.subLanguage])return u(x);var t=e?m(b.subLanguage,x,!0,w[b.subLanguage]):v(x,b.subLanguage.length?b.subLanguage:void 0);return b.relevance>0&&(S+=t.relevance),e&&(w[b.subLanguage]=t.top),a(t.language,t.value,!1,!0)}():function(){var e,t,n,r;if(!b.keywords)return u(x);for(r="",t=0,b.lexemesRe.lastIndex=0,n=b.lexemesRe.exec(x);n;)r+=u(x.substring(t,n.index)),(e=o(b,n))?(S+=e[1],r+=a(e[0],u(n[0]))):r+=u(n[0]),t=b.lexemesRe.lastIndex,n=b.lexemesRe.exec(x);return r+u(x.substr(t))}(),x=""}function d(e){E+=e.className?a(e.className,"",!0):"",b=Object.create(e,{parent:{value:b}})}function f(e,t){if(x+=e,null==t)return l(),0;var r=function(e,t){var n,r;for(n=0,r=t.contains.length;n<r;n++)if(h(t.contains[n].beginRe,e))return t.contains[n].endSameAsBegin&&(t.contains[n].endRe=s(t.contains[n].beginRe.exec(e)[0])),t.contains[n]}(t,b);if(r)return r.skip?x+=t:(r.excludeBegin&&(x+=t),l(),r.returnBegin||r.excludeBegin||(x=t)),d(r),r.returnBegin?0:t.length;var i=function e(t,n){if(h(t.endRe,n)){for(;t.endsParent&&t.parent;)t=t.parent;return t}if(t.endsWithParent)return e(t.parent,n)}(b,t);if(i){var o=b;o.skip?x+=t:(o.returnEnd||o.excludeEnd||(x+=t),l(),o.excludeEnd&&(x=t));do{b.className&&(E+="</span>"),b.skip||b.subLanguage||(S+=b.relevance),b=b.parent}while(b!==i.parent);return i.starts&&(i.endSameAsBegin&&(i.starts.endRe=i.endRe),d(i.starts)),o.returnEnd?0:t.length}if(function(e,t){return!n&&h(t.illegalRe,e)}(t,b))throw new Error('Illegal lexeme "'+t+'" for mode "'+(b.className||"<unnamed>")+'"');return x+=t,t.length||1}var p=_(e);if(!p)throw new Error('Unknown language: "'+e+'"');g(p);var y,b=i||p,w={},E="";for(y=b;y!==p;y=y.parent)y.className&&(E=a(y.className,"",!0)+E);var x="",S=0;try{for(var C,A,N=0;b.terminators.lastIndex=N,C=b.terminators.exec(t);)A=f(t.substring(N,C.index),C[0]),N=C.index+A;for(f(t.substr(N)),y=b;y.parent;y=y.parent)y.className&&(E+="</span>");return{relevance:S,value:E,language:e,top:b}}catch(e){if(e.message&&-1!==e.message.indexOf("Illegal"))return{relevance:0,value:u(t)};throw e}}function v(e,t){t=t||c.languages||n(r);var i={relevance:0,value:u(e)},s=i;return t.filter(_).filter(E).forEach((function(t){var n=m(t,e,!1);n.language=t,n.relevance>s.relevance&&(s=n),n.relevance>i.relevance&&(s=i,i=n)})),s.language&&(i.second_best=s),i}function y(e){return c.tabReplace||c.useBR?e.replace(a,(function(e,t){return c.useBR&&"\n"===e?"<br>":c.tabReplace?t.replace(/\t/g,c.tabReplace):""})):e}function b(e){var n,r,s,a,h,f=function(e){var t,n,r,i,s=e.className+" ";if(s+=e.parentNode?e.parentNode.className:"",n=o.exec(s))return _(n[1])?n[1]:"no-highlight";for(t=0,r=(s=s.split(/\s+/)).length;t<r;t++)if(d(i=s[t])||_(i))return i}(e);d(f)||(c.useBR?(n=document.createElementNS("http://www.w3.org/1999/xhtml","div")).innerHTML=e.innerHTML.replace(/\n/g,"").replace(/<br[ \/]*>/g,"\n"):n=e,h=n.textContent,s=f?m(f,h,!0):v(h),(r=p(n)).length&&((a=document.createElementNS("http://www.w3.org/1999/xhtml","div")).innerHTML=s.value,s.value=function(e,n,r){var i=0,s="",o=[];function a(){return e.length&&n.length?e[0].offset!==n[0].offset?e[0].offset<n[0].offset?e:n:"start"===n[0].event?e:n:e.length?e:n}function c(e){s+="<"+l(e)+t.map.call(e.attributes,(function(e){return" "+e.nodeName+'="'+u(e.value).replace('"',"&quot;")+'"'})).join("")+">"}function h(e){s+="</"+l(e)+">"}function d(e){("start"===e.event?c:h)(e.node)}for(;e.length||n.length;){var f=a();if(s+=u(r.substring(i,f[0].offset)),i=f[0].offset,f===e){o.reverse().forEach(h);do{d(f.splice(0,1)[0]),f=a()}while(f===e&&f.length&&f[0].offset===i);o.reverse().forEach(c)}else"start"===f[0].event?o.push(f[0].node):o.pop(),d(f.splice(0,1)[0])}return s+u(r.substr(i))}(r,p(a),h)),s.value=y(s.value),e.innerHTML=s.value,e.className=function(e,t,n){var r=t?i[t]:n,s=[e.trim()];return e.match(/\bhljs\b/)||s.push("hljs"),-1===e.indexOf(r)&&s.push(r),s.join(" ").trim()}(e.className,f,s.language),e.result={language:s.language,re:s.relevance},s.second_best&&(e.second_best={language:s.second_best.language,re:s.second_best.relevance}))}function w(){if(!w.called){w.called=!0;var e=document.querySelectorAll("pre code");t.forEach.call(e,b)}}function _(e){return e=(e||"").toLowerCase(),r[e]||r[i[e]]}function E(e){var t=_(e);return t&&!t.disableAutodetect}e.highlight=m,e.highlightAuto=v,e.fixMarkup=y,e.highlightBlock=b,e.configure=function(e){c=f(c,e)},e.initHighlighting=w,e.initHighlightingOnLoad=function(){addEventListener("DOMContentLoaded",w,!1),addEventListener("load",w,!1)},e.registerLanguage=function(t,n){var s=r[t]=n(e);s.aliases&&s.aliases.forEach((function(e){i[e]=t}))},e.listLanguages=function(){return n(r)},e.getLanguage=_,e.autoDetection=E,e.inherit=f,e.IDENT_RE="[a-zA-Z]\\w*",e.UNDERSCORE_IDENT_RE="[a-zA-Z_]\\w*",e.NUMBER_RE="\\b\\d+(\\.\\d+)?",e.C_NUMBER_RE="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",e.BINARY_NUMBER_RE="\\b(0b[01]+)",e.RE_STARTERS_RE="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",e.BACKSLASH_ESCAPE={begin:"\\\\[\\s\\S]",relevance:0},e.APOS_STRING_MODE={className:"string",begin:"'",end:"'",illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]},e.QUOTE_STRING_MODE={className:"string",begin:'"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]},e.PHRASAL_WORDS_MODE={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},e.COMMENT=function(t,n,r){var i=e.inherit({className:"comment",begin:t,end:n,contains:[]},r||{});return i.contains.push(e.PHRASAL_WORDS_MODE),i.contains.push({className:"doctag",begin:"(?:TODO|FIXME|NOTE|BUG|XXX):",relevance:0}),i},e.C_LINE_COMMENT_MODE=e.COMMENT("//","$"),e.C_BLOCK_COMMENT_MODE=e.COMMENT("/\\*","\\*/"),e.HASH_COMMENT_MODE=e.COMMENT("#","$"),e.NUMBER_MODE={className:"number",begin:e.NUMBER_RE,relevance:0},e.C_NUMBER_MODE={className:"number",begin:e.C_NUMBER_RE,relevance:0},e.BINARY_NUMBER_MODE={className:"number",begin:e.BINARY_NUMBER_RE,relevance:0},e.CSS_NUMBER_MODE={className:"number",begin:e.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},e.REGEXP_MODE={className:"regexp",begin:/\//,end:/\/[gimuy]*/,illegal:/\n/,contains:[e.BACKSLASH_ESCAPE,{begin:/\[/,end:/\]/,relevance:0,contains:[e.BACKSLASH_ESCAPE]}]},e.TITLE_MODE={className:"title",begin:e.IDENT_RE,relevance:0},e.UNDERSCORE_TITLE_MODE={className:"title",begin:e.UNDERSCORE_IDENT_RE,relevance:0},e.METHOD_GUARD={begin:"\\.\\s*"+e.UNDERSCORE_IDENT_RE,relevance:0}})(t)}()},function(e,t){e.exports=function(e){var t={className:"variable",variants:[{begin:/\$[\w\d#@][\w\d_]*/},{begin:/\$\{(.*?)}/}]},n={className:"string",begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,t,{className:"variable",begin:/\$\(/,end:/\)/,contains:[e.BACKSLASH_ESCAPE]}]};return{aliases:["sh","zsh"],lexemes:/\b-?[a-z\._]+\b/,keywords:{keyword:"if then else elif fi for while in do done case esac function",literal:"true false",built_in:"break cd continue eval exec exit export getopts hash pwd readonly return shift test times trap umask unset alias bind builtin caller command declare echo enable help let local logout mapfile printf read readarray source type typeset ulimit unalias set shopt autoload bg bindkey bye cap chdir clone comparguments compcall compctl compdescribe compfiles compgroups compquote comptags comptry compvalues dirs disable disown echotc echoti emulate fc fg float functions getcap getln history integer jobs kill limit log noglob popd print pushd pushln rehash sched setcap setopt stat suspend ttyctl unfunction unhash unlimit unsetopt vared wait whence where which zcompile zformat zftp zle zmodload zparseopts zprof zpty zregexparse zsocket zstyle ztcp",_:"-ne -eq -lt -gt -f -d -e -s -l -a"},contains:[{className:"meta",begin:/^#![^\n]+sh\s*$/,relevance:10},{className:"function",begin:/\w[\w\d_]*\s*\(\s*\)\s*\{/,returnBegin:!0,contains:[e.inherit(e.TITLE_MODE,{begin:/\w[\w\d_]*/})],relevance:0},e.HASH_COMMENT_MODE,n,{className:"string",begin:/'/,end:/'/},t]}}},function(e,t){e.exports=function(e){var t={begin:/[A-Z\_\.\-]+\s*:/,returnBegin:!0,end:";",endsWithParent:!0,contains:[{className:"attribute",begin:/\S/,end:":",excludeEnd:!0,starts:{endsWithParent:!0,excludeEnd:!0,contains:[{begin:/[\w-]+\(/,returnBegin:!0,contains:[{className:"built_in",begin:/[\w-]+/},{begin:/\(/,end:/\)/,contains:[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]}]},e.CSS_NUMBER_MODE,e.QUOTE_STRING_MODE,e.APOS_STRING_MODE,e.C_BLOCK_COMMENT_MODE,{className:"number",begin:"#[0-9A-Fa-f]+"},{className:"meta",begin:"!important"}]}}]};return{case_insensitive:!0,illegal:/[=\/|'\$]/,contains:[e.C_BLOCK_COMMENT_MODE,{className:"selector-id",begin:/#[A-Za-z0-9_-]+/},{className:"selector-class",begin:/\.[A-Za-z0-9_-]+/},{className:"selector-attr",begin:/\[/,end:/\]/,illegal:"$"},{className:"selector-pseudo",begin:/:(:)?[a-zA-Z0-9\_\-\+\(\)"'.]+/},{begin:"@(font-face|page)",lexemes:"[a-z-]+",keywords:"font-face page"},{begin:"@",end:"[{;]",illegal:/:/,contains:[{className:"keyword",begin:/\w+/},{begin:/\s/,endsWithParent:!0,excludeEnd:!0,relevance:0,contains:[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,e.CSS_NUMBER_MODE]}]},{className:"selector-tag",begin:"[a-zA-Z-][a-zA-Z0-9_-]*",relevance:0},{begin:"{",end:"}",illegal:/\S/,contains:[e.C_BLOCK_COMMENT_MODE,t]}]}}},function(e,t){e.exports=function(e){return{aliases:["md","mkdown","mkd"],contains:[{className:"section",variants:[{begin:"^#{1,6}",end:"$"},{begin:"^.+?\\n[=-]{2,}$"}]},{begin:"<",end:">",subLanguage:"xml",relevance:0},{className:"bullet",begin:"^([*+-]|(\\d+\\.))\\s+"},{className:"strong",begin:"[*_]{2}.+?[*_]{2}"},{className:"emphasis",variants:[{begin:"\\*.+?\\*"},{begin:"_.+?_",relevance:0}]},{className:"quote",begin:"^>\\s+",end:"$"},{className:"code",variants:[{begin:"^```w*s*$",end:"^```s*$"},{begin:"`.+?`"},{begin:"^( {4}|\t)",end:"$",relevance:0}]},{begin:"^[-\\*]{3,}",end:"$"},{begin:"\\[.+?\\][\\(\\[].*?[\\)\\]]",returnBegin:!0,contains:[{className:"string",begin:"\\[",end:"\\]",excludeBegin:!0,returnEnd:!0,relevance:0},{className:"link",begin:"\\]\\(",end:"\\)",excludeBegin:!0,excludeEnd:!0},{className:"symbol",begin:"\\]\\[",end:"\\]",excludeBegin:!0,excludeEnd:!0}],relevance:10},{begin:/^\[[^\n]+\]:/,returnBegin:!0,contains:[{className:"symbol",begin:/\[/,end:/\]/,excludeBegin:!0,excludeEnd:!0},{className:"link",begin:/:\s*/,end:/$/,excludeBegin:!0}]}]}}},function(e,t){e.exports=function(e){return{aliases:["patch"],contains:[{className:"meta",relevance:10,variants:[{begin:/^@@ +\-\d+,\d+ +\+\d+,\d+ +@@$/},{begin:/^\*\*\* +\d+,\d+ +\*\*\*\*$/},{begin:/^\-\-\- +\d+,\d+ +\-\-\-\-$/}]},{className:"comment",variants:[{begin:/Index: /,end:/$/},{begin:/={3,}/,end:/$/},{begin:/^\-{3}/,end:/$/},{begin:/^\*{3} /,end:/$/},{begin:/^\+{3}/,end:/$/},{begin:/\*{5}/,end:/\*{5}$/}]},{className:"addition",begin:"^\\+",end:"$"},{className:"deletion",begin:"^\\-",end:"$"},{className:"addition",begin:"^\\!",end:"$"}]}}},function(e,t){e.exports=function(e){var t="[A-Za-z$_][0-9A-Za-z$_]*",n={keyword:"in of if for while finally var new function do return void else break catch instanceof with throw case default try this switch continue typeof delete let yield const export super debugger as async await static import from as",literal:"true false null undefined NaN Infinity",built_in:"eval isFinite isNaN parseFloat parseInt decodeURI decodeURIComponent encodeURI encodeURIComponent escape unescape Object Function Boolean Error EvalError InternalError RangeError ReferenceError StopIteration SyntaxError TypeError URIError Number Math Date String RegExp Array Float32Array Float64Array Int16Array Int32Array Int8Array Uint16Array Uint32Array Uint8Array Uint8ClampedArray ArrayBuffer DataView JSON Intl arguments require module console window document Symbol Set Map WeakSet WeakMap Proxy Reflect Promise"},r={className:"number",variants:[{begin:"\\b(0[bB][01]+)"},{begin:"\\b(0[oO][0-7]+)"},{begin:e.C_NUMBER_RE}],relevance:0},i={className:"subst",begin:"\\$\\{",end:"\\}",keywords:n,contains:[]},s={className:"string",begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE,i]};i.contains=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,s,r,e.REGEXP_MODE];var o=i.contains.concat([e.C_BLOCK_COMMENT_MODE,e.C_LINE_COMMENT_MODE]);return{aliases:["js","jsx"],keywords:n,contains:[{className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},{className:"meta",begin:/^#!/,end:/$/},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,s,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,r,{begin:/[{,]\s*/,relevance:0,contains:[{begin:t+"\\s*:",returnBegin:!0,relevance:0,contains:[{className:"attr",begin:t,relevance:0}]}]},{begin:"("+e.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",contains:[e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,e.REGEXP_MODE,{className:"function",begin:"(\\(.*?\\)|"+t+")\\s*=>",returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:t},{begin:/\(\s*\)/},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:n,contains:o}]}]},{begin:/</,end:/(\/\w+|\w+\/)>/,subLanguage:"xml",contains:[{begin:/<\w+\s*\/>/,skip:!0},{begin:/<\w+/,end:/(\/\w+|\w+\/)>/,skip:!0,contains:[{begin:/<\w+\s*\/>/,skip:!0},"self"]}]}],relevance:0},{className:"function",beginKeywords:"function",end:/\{/,excludeEnd:!0,contains:[e.inherit(e.TITLE_MODE,{begin:t}),{className:"params",begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,contains:o}],illegal:/\[|%/},{begin:/\$[(.]/},e.METHOD_GUARD,{className:"class",beginKeywords:"class",end:/[{;=]/,excludeEnd:!0,illegal:/[:"\[\]]/,contains:[{beginKeywords:"extends"},e.UNDERSCORE_TITLE_MODE]},{beginKeywords:"constructor",end:/\{/,excludeEnd:!0}],illegal:/#(?!!)/}}},function(e,t){e.exports=function(e){var t={literal:"true false null"},n=[e.QUOTE_STRING_MODE,e.C_NUMBER_MODE],r={end:",",endsWithParent:!0,excludeEnd:!0,contains:n,keywords:t},i={begin:"{",end:"}",contains:[{className:"attr",begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE],illegal:"\\n"},e.inherit(r,{begin:/:/})],illegal:"\\S"},s={begin:"\\[",end:"\\]",contains:[e.inherit(r)],illegal:"\\S"};return n.splice(n.length,0,i,s),{contains:n,keywords:t,illegal:"\\S"}}},function(e,t){e.exports=function(e){var t="[a-zA-Z_][\\w\\-]*",n={className:"attr",variants:[{begin:"^[ \\-]*"+t+":"},{begin:'^[ \\-]*"'+t+'":'},{begin:"^[ \\-]*'"+t+"':"}]},r={className:"string",relevance:0,variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/\S+/}],contains:[e.BACKSLASH_ESCAPE,{className:"template-variable",variants:[{begin:"{{",end:"}}"},{begin:"%{",end:"}"}]}]};return{case_insensitive:!0,aliases:["yml","YAML","yaml"],contains:[n,{className:"meta",begin:"^---s*$",relevance:10},{className:"string",begin:"[\\|>] *$",returnEnd:!0,contains:r.contains,end:n.variants[0].begin},{begin:"<%[%=-]?",end:"[%-]?%>",subLanguage:"ruby",excludeBegin:!0,excludeEnd:!0,relevance:0},{className:"type",begin:"!"+e.UNDERSCORE_IDENT_RE},{className:"type",begin:"!!"+e.UNDERSCORE_IDENT_RE},{className:"meta",begin:"&"+e.UNDERSCORE_IDENT_RE+"$"},{className:"meta",begin:"\\*"+e.UNDERSCORE_IDENT_RE+"$"},{className:"bullet",begin:"^ *-",relevance:0},e.HASH_COMMENT_MODE,{beginKeywords:"true false yes no null",keywords:{literal:"true false yes no null"}},e.C_NUMBER_MODE,r]}}},function(e,t){e.exports=function(e){var t={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:"[A-Za-z0-9\\._:-]+",relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/},{begin:/'/,end:/'/},{begin:/[^\s"'=<>`]+/}]}]}]};return{aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist"],case_insensitive:!0,contains:[{className:"meta",begin:"<!DOCTYPE",end:">",relevance:10,contains:[{begin:"\\[",end:"\\]"}]},e.COMMENT("\x3c!--","--\x3e",{relevance:10}),{begin:"<\\!\\[CDATA\\[",end:"\\]\\]>",relevance:10},{className:"meta",begin:/<\?xml/,end:/\?>/,relevance:10},{begin:/<\?(php)?/,end:/\?>/,subLanguage:"php",contains:[{begin:"/\\*",end:"\\*/",skip:!0},{begin:'b"',end:'"',skip:!0},{begin:"b'",end:"'",skip:!0},e.inherit(e.APOS_STRING_MODE,{illegal:null,className:null,contains:null,skip:!0}),e.inherit(e.QUOTE_STRING_MODE,{illegal:null,className:null,contains:null,skip:!0})]},{className:"tag",begin:"<style(?=\\s|>|$)",end:">",keywords:{name:"style"},contains:[t],starts:{end:"</style>",returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:"<script(?=\\s|>|$)",end:">",keywords:{name:"script"},contains:[t],starts:{end:"<\/script>",returnEnd:!0,subLanguage:["actionscript","javascript","handlebars","xml"]}},{className:"tag",begin:"</?",end:"/?>",contains:[{className:"name",begin:/[^\/><\s]+/,relevance:0},t]}]}}},function(e,t){e.exports=function(e){var t={"builtin-name":"each in with if else unless bindattr action collection debugger log outlet template unbound view yield"};return{aliases:["hbs","html.hbs","html.handlebars"],case_insensitive:!0,subLanguage:"xml",contains:[e.COMMENT("{{!(--)?","(--)?}}"),{className:"template-tag",begin:/\{\{[#\/]/,end:/\}\}/,contains:[{className:"name",begin:/[a-zA-Z\.-]+/,keywords:t,starts:{endsWithParent:!0,relevance:0,contains:[e.QUOTE_STRING_MODE]}}]},{className:"template-variable",begin:/\{\{/,end:/\}\}/,keywords:t}]}}},function(e,t,n){n(0),n(21)},function(e,t,n){!function(t,r){var i=function(){r(t.lazySizes),t.removeEventListener("lazyunveilread",i,!0)};r=r.bind(null,t,t.document),e.exports?r(n(0)):t.lazySizes?i():t.addEventListener("lazyunveilread",i,!0)}(window,(function(e,t,n){"use strict";var r,i,s={};function o(e,n){if(!s[e]){var r=t.createElement(n?"link":"script"),i=t.getElementsByTagName("script")[0];n?(r.rel="stylesheet",r.href=e):r.src=e,s[e]=!0,s[r.src||r.href]=!0,i.parentNode.insertBefore(r,i)}}t.addEventListener&&(i=/\(|\)|\s|'/,r=function(e,n){var r=t.createElement("img");r.onload=function(){r.onload=null,r.onerror=null,r=null,n()},r.onerror=r.onload,r.src=e,r&&r.complete&&r.onload&&r.onload()},addEventListener("lazybeforeunveil",(function(e){var t,s,a;e.detail.instance==n&&(e.defaultPrevented||("none"==e.target.preload&&(e.target.preload="auto"),(t=e.target.getAttribute("data-link"))&&o(t,!0),(t=e.target.getAttribute("data-script"))&&o(t),(t=e.target.getAttribute("data-require"))&&(n.cfg.requireJs?n.cfg.requireJs([t]):o(t)),(s=e.target.getAttribute("data-bg"))&&(e.detail.firesLoad=!0,r(s,(function(){e.target.style.backgroundImage="url("+(i.test(s)?JSON.stringify(s):s)+")",e.detail.firesLoad=!1,n.fire(e.target,"_lazyloaded",{},!0,!0)}))),(a=e.target.getAttribute("data-poster"))&&(e.detail.firesLoad=!0,r(a,(function(){e.target.poster=a,e.detail.firesLoad=!1,n.fire(e.target,"_lazyloaded",{},!0,!0)})))))}),!1))}))},function(e,t){for(var n=document.getElementsByClassName("js-toggle"),r=0;r<n.length;r++)n[r].addEventListener("click",i,!1);function i(){for(var e=this.dataset.target.split(" "),t=document.querySelector(".mobilemenu:not(.dn)"),n=document.querySelector(".desktopmenu:not(.dn)"),r=document.querySelector(".desktopmenu:not(.dn)"),i=0;i<e.length;i++){var s=document.querySelectorAll(e[i]);[].forEach.call(s,(function(e){return e.classList.contains("dn")?e.classList.remove("dn"):e.classList.add("dn"),!1})),t&&t.classList.add("dn"),n&&n.classList.add("dn"),r&&r.classList.remove("db")}}},function(e,t,n){n(24)},function(e,t,n){!function(){"use strict";var e,t,n="data-scrolldir",r="down",i=document.documentElement,s=window,o=document.body,a=Array(32),c=0;function u(){var u=s.scrollY||s.pageYOffset,l=e.timeStamp,h="down"===r?Math.max:Math.min,d=o.scrollHeight-s.innerHeight;if(u=Math.max(0,u),u=Math.min(d,u),a.unshift({y:u,t:l}),a.pop(),u===h(t,u))return c=l,void(t=u);var f=l-512;if(c<f){t=u;for(var p=0;p<32&&a[p]&&!(a[p].t<f);p+=1)t=h(t,a[p].y)}Math.abs(u-t)>64&&(t=u,c=l,r="down"===r?"up":"down",i.setAttribute(n,r))}function l(t){return e=t,s.requestAnimationFrame(u)}t=s.scrollY||s.pageYOffset,i.setAttribute(n,r),s.addEventListener("scroll",l)}()},function(e,t){!function(){"use strict";if("querySelector"in document&&"addEventListener"in window&&Array.prototype.forEach){var e=document.querySelectorAll("#TableOfContents ul li a");[].forEach.call(e,(function(e){e.addEventListener("click",(function(t){t.preventDefault();var n=e.getAttribute("href"),r=document.querySelector(n),i=e.getAttribute("data-speed");r&&function(e,t){var n,r=window.pageYOffset,i=e.offsetTop,s=(i-r)/(t/16);n=s>=0?function(){var e=window.pageYOffset;(e>=i-s||window.innerHeight+e>=document.body.offsetHeight)&&clearInterval(o)}:function(){window.pageYOffset<=(i||0)&&clearInterval(o)};var o=setInterval((function(){window.scrollBy(0,s),n()}),16)}(r,i||500)}),!1)}))}}()},function(e,t){var n,r=document.querySelectorAll("[data-toggle-tab]"),i=document.querySelectorAll("[data-pane]");function s(e){if(e.target){e.preventDefault();var t=e.currentTarget.getAttribute("data-toggle-tab")}else t=e;window.localStorage&&window.localStorage.setItem("configLangPref",t);for(var n=document.querySelectorAll("[data-toggle-tab='"+t+"']"),s=document.querySelectorAll("[data-pane='"+t+"']"),o=0;o<r.length;o++)r[o].classList.remove("active"),i[o].classList.remove("active");for(o=0;o<n.length;o++)n[o].classList.add("active"),s[o].classList.add("active")}for(n=0;n<r.length;n++)r[n].addEventListener("click",s);window.localStorage.getItem("configLangPref")&&s(window.localStorage.getItem("configLangPref"))},function(e,t){document.documentElement.className=document.documentElement.className.replace(/\bno-js\b/,"js")}]); \ No newline at end of file
+ */var r;r=function(){"use strict";function t(t){return"function"==typeof t}var r=Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)},i=0,o=void 0,s=void 0,a=function(t,e){p[i]=t,p[i+1]=e,2===(i+=2)&&(s?s(g):w())},u="undefined"!=typeof window?window:void 0,c=u||{},l=c.MutationObserver||c.WebKitMutationObserver,h="undefined"==typeof self&&void 0!==e&&"[object process]"==={}.toString.call(e),f="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function d(){var t=setTimeout;return function(){return t(g,1)}}var p=new Array(1e3);function g(){for(var t=0;t<i;t+=2)(0,p[t])(p[t+1]),p[t]=void 0,p[t+1]=void 0;i=0}var m,y,v,b,w=void 0;function _(t,e){var n=this,r=new this.constructor(C);void 0===r[S]&&D(r);var i=n._state;if(i){var o=arguments[i-1];a((function(){return L(i,r,o,n._result)}))}else I(n,r,t,e);return r}function x(t){if(t&&"object"==typeof t&&t.constructor===this)return t;var e=new this(C);return k(e,t),e}h?w=function(){return e.nextTick(g)}:l?(y=0,v=new l(g),b=document.createTextNode(""),v.observe(b,{characterData:!0}),w=function(){b.data=y=++y%2}):f?((m=new MessageChannel).port1.onmessage=g,w=function(){return m.port2.postMessage(0)}):w=void 0===u?function(){try{var t=Function("return this")().require("vertx");return void 0!==(o=t.runOnLoop||t.runOnContext)?function(){o(g)}:d()}catch(t){return d()}}():d();var S=Math.random().toString(36).substring(2);function C(){}var A={error:null};function E(t){try{return t.then}catch(t){return A.error=t,A}}function T(e,n,r){n.constructor===e.constructor&&r===_&&n.constructor.resolve===x?function(t,e){1===e._state?N(t,e._result):2===e._state?j(t,e._result):I(e,void 0,(function(e){return k(t,e)}),(function(e){return j(t,e)}))}(e,n):r===A?(j(e,A.error),A.error=null):void 0===r?N(e,n):t(r)?function(t,e,n){a((function(t){var r=!1,i=function(t,e,n,r){try{t.call(e,n,r)}catch(t){return t}}(n,e,(function(n){r||(r=!0,e!==n?k(t,n):N(t,n))}),(function(e){r||(r=!0,j(t,e))}),t._label);!r&&i&&(r=!0,j(t,i))}),t)}(e,n,r):N(e,n)}function k(t,e){var n,r;t===e?j(t,new TypeError("You cannot resolve a promise with itself")):(r=typeof(n=e),null===n||"object"!==r&&"function"!==r?N(t,e):T(t,e,E(e)))}function O(t){t._onerror&&t._onerror(t._result),R(t)}function N(t,e){void 0===t._state&&(t._result=e,t._state=1,0!==t._subscribers.length&&a(R,t))}function j(t,e){void 0===t._state&&(t._state=2,t._result=e,a(O,t))}function I(t,e,n,r){var i=t._subscribers,o=i.length;t._onerror=null,i[o]=e,i[o+1]=n,i[o+2]=r,0===o&&t._state&&a(R,t)}function R(t){var e=t._subscribers,n=t._state;if(0!==e.length){for(var r=void 0,i=void 0,o=t._result,s=0;s<e.length;s+=3)r=e[s],i=e[s+n],r?L(n,r,i,o):i(o);t._subscribers.length=0}}function L(e,n,r,i){var o=t(r),s=void 0,a=void 0,u=void 0,c=void 0;if(o){if((s=function(t,e){try{return t(e)}catch(t){return A.error=t,A}}(r,i))===A?(c=!0,a=s.error,s.error=null):u=!0,n===s)return void j(n,new TypeError("A promises callback cannot return that same promise."))}else s=i,u=!0;void 0!==n._state||(o&&u?k(n,s):c?j(n,a):1===e?N(n,s):2===e&&j(n,s))}var P=0;function D(t){t[S]=P++,t._state=void 0,t._result=void 0,t._subscribers=[]}var $=function(){function t(t,e){this._instanceConstructor=t,this.promise=new t(C),this.promise[S]||D(this.promise),r(e)?(this.length=e.length,this._remaining=e.length,this._result=new Array(this.length),0===this.length?N(this.promise,this._result):(this.length=this.length||0,this._enumerate(e),0===this._remaining&&N(this.promise,this._result))):j(this.promise,new Error("Array Methods must be provided an Array"))}return t.prototype._enumerate=function(t){for(var e=0;void 0===this._state&&e<t.length;e++)this._eachEntry(t[e],e)},t.prototype._eachEntry=function(t,e){var n=this._instanceConstructor,r=n.resolve;if(r===x){var i=E(t);if(i===_&&void 0!==t._state)this._settledAt(t._state,e,t._result);else if("function"!=typeof i)this._remaining--,this._result[e]=t;else if(n===q){var o=new n(C);T(o,t,i),this._willSettleAt(o,e)}else this._willSettleAt(new n((function(e){return e(t)})),e)}else this._willSettleAt(r(t),e)},t.prototype._settledAt=function(t,e,n){var r=this.promise;void 0===r._state&&(this._remaining--,2===t?j(r,n):this._result[e]=n),0===this._remaining&&N(r,this._result)},t.prototype._willSettleAt=function(t,e){var n=this;I(t,void 0,(function(t){return n._settledAt(1,e,t)}),(function(t){return n._settledAt(2,e,t)}))},t}(),q=function(){function t(e){this[S]=P++,this._result=this._state=void 0,this._subscribers=[],C!==e&&("function"!=typeof e&&function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof t?function(t,e){try{e((function(e){k(t,e)}),(function(e){j(t,e)}))}catch(e){j(t,e)}}(this,e):function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}())}return t.prototype.catch=function(t){return this.then(null,t)},t.prototype.finally=function(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){throw n}))}))},t}();return q.prototype.then=_,q.all=function(t){return new $(this,t).promise},q.race=function(t){var e=this;return r(t)?new e((function(n,r){for(var i=t.length,o=0;o<i;o++)e.resolve(t[o]).then(n,r)})):new e((function(t,e){return e(new TypeError("You must pass an array to race."))}))},q.resolve=x,q.reject=function(t){var e=new this(C);return j(e,t),e},q._setScheduler=function(t){s=t},q._setAsap=function(t){a=t},q._asap=a,q.polyfill=function(){var t=void 0;if(void 0!==n)t=n;else if("undefined"!=typeof self)t=self;else try{t=Function("return this")()}catch(t){throw new Error("polyfill failed because global object is unavailable in this environment")}var e=t.Promise;if(e){var r=null;try{r=Object.prototype.toString.call(e.resolve())}catch(t){}if("[object Promise]"===r&&!e.cast)return}t.Promise=q},q.Promise=q,q},t.exports=r()}).call(e,n(9),n(4))},function(t,e,n){"use strict";t.exports=function(t,e){return/\?/.test(t)?t+="&":t+="?",t+r(e)};var r=n(45)},function(t,e,n){"use strict";var r=function(t){switch(typeof t){case"string":return t;case"boolean":return t?"true":"false";case"number":return isFinite(t)?t:"";default:return""}};t.exports=function(t,e,n,a){return e=e||"&",n=n||"=",null===t&&(t=void 0),"object"==typeof t?o(s(t),(function(s){var a=encodeURIComponent(r(s))+n;return i(t[s])?o(t[s],(function(t){return a+encodeURIComponent(r(t))})).join(e):a+encodeURIComponent(r(t[s]))})).join(e):a?encodeURIComponent(r(a))+n+encodeURIComponent(r(t)):""};var i=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)};function o(t,e){if(t.map)return t.map(e);for(var n=[],r=0;r<t.length;r++)n.push(e(t[r],r));return n}var s=Object.keys||function(t){var e=[];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.push(n);return e}},function(t,e,n){"use strict";t.exports=function(t,e,n){if("GET"===e.method){e.debug("JSONP: start");var o=!1,s=!1;i+=1;var a=document.getElementsByTagName("head")[0],u=document.createElement("script"),c="algoliaJSONP_"+i,l=!1;window[c]=function(t){!function(){try{delete window[c],delete window[c+"_loaded"]}catch(t){window[c]=window[c+"_loaded"]=void 0}}(),s?e.debug("JSONP: Late answer, ignoring"):(o=!0,d(),n(null,{body:t,responseText:JSON.stringify(t)}))},t+="&callback="+c,e.jsonBody&&e.jsonBody.params&&(t+="&"+e.jsonBody.params);var h=setTimeout((function(){e.debug("JSONP: Script timeout"),s=!0,d(),n(new r.RequestTimeout)}),e.timeouts.complete);u.onreadystatechange=function(){"loaded"!==this.readyState&&"complete"!==this.readyState||f()},u.onload=f,u.onerror=function(){e.debug("JSONP: Script error"),l||s||(d(),n(new r.JSONPScriptError))},u.async=!0,u.defer=!0,u.src=t,a.appendChild(u)}else n(new Error("Method "+e.method+" "+t+" is not supported by JSONP."));function f(){e.debug("JSONP: success"),l||s||(l=!0,o||(e.debug("JSONP: Fail. Script loaded but did not call the callback"),d(),n(new r.JSONPScriptFail)))}function d(){clearTimeout(h),u.onload=null,u.onreadystatechange=null,u.onerror=null,a.removeChild(u)}};var r=n(5),i=0},function(t,e,n){t.exports=function(t){return function(e,i,o){var s=n(3);(o=o&&s(o)||{}).hosts=o.hosts||["places-dsn.algolia.net","places-1.algolianet.com","places-2.algolianet.com","places-3.algolianet.com"],0!==arguments.length&&"object"!=typeof e&&void 0!==e||(e="",i="",o._allowEmptyCredentials=!0);var a=t(e,i,o),u=a.initIndex("places");return u.search=r("query","/1/places/query"),u.getObject=function(t,e){return this.as._jsonRequest({method:"GET",url:"/1/places/"+encodeURIComponent(t),hostType:"read",callback:e})},u}};var r=n(13)},function(t,e,n){"use strict";t.exports="3.30.0"},function(t,e,n){"use strict";t.exports=n(50)},function(t,e,n){"use strict";var r=n(15);n(1).element=r;var i=n(0);i.isArray=r.isArray,i.isFunction=r.isFunction,i.isObject=r.isPlainObject,i.bind=r.proxy,i.each=function(t,e){r.each(t,(function(t,n){return e(n,t)}))},i.map=r.map,i.mixin=r.extend,i.Event=r.Event;var o=n(51),s=n(16);function a(t,e,n,a){n=i.isArray(n)?n:[].slice.call(arguments,2);var u=r(t).each((function(t,i){var u=r(i),c=new s({el:u}),l=a||new o({input:u,eventBus:c,dropdownMenuContainer:e.dropdownMenuContainer,hint:void 0===e.hint||!!e.hint,minLength:e.minLength,autoselect:e.autoselect,autoselectOnBlur:e.autoselectOnBlur,tabAutocomplete:e.tabAutocomplete,openOnFocus:e.openOnFocus,templates:e.templates,debug:e.debug,clearOnSelected:e.clearOnSelected,cssClasses:e.cssClasses,datasets:n,keyboardShortcuts:e.keyboardShortcuts,appendTo:e.appendTo,autoWidth:e.autoWidth});u.data("aaAutocomplete",l)}));return u.autocomplete={},i.each(["open","close","getVal","setVal","destroy","getWrapper"],(function(t){u.autocomplete[t]=function(){var e,n=arguments;return u.each((function(i,o){var s=r(o).data("aaAutocomplete");e=s[t].apply(s,n)})),e}})),u}a.sources=o.sources,a.escapeHighlightedString=i.escapeHighlightedString;var u="autocomplete"in window,c=window.autocomplete;a.noConflict=function(){return u?window.autocomplete=c:delete window.autocomplete,a},t.exports=a},function(t,e,n){"use strict";var r=n(0),i=n(1),o=n(16),s=n(52),a=n(59),u=n(17),c=n(11);function l(t){var e,n;if((t=t||{}).input||r.error("missing input"),this.isActivated=!1,this.debug=!!t.debug,this.autoselect=!!t.autoselect,this.autoselectOnBlur=!!t.autoselectOnBlur,this.openOnFocus=!!t.openOnFocus,this.minLength=r.isNumber(t.minLength)?t.minLength:1,this.autoWidth=void 0===t.autoWidth||!!t.autoWidth,this.clearOnSelected=!!t.clearOnSelected,this.tabAutocomplete=void 0===t.tabAutocomplete||!!t.tabAutocomplete,t.hint=!!t.hint,t.hint&&t.appendTo)throw new Error("[autocomplete.js] hint and appendTo options can't be used at the same time");this.css=t.css=r.mixin({},c,t.appendTo?c.appendTo:{}),this.cssClasses=t.cssClasses=r.mixin({},c.defaultClasses,t.cssClasses||{}),this.cssClasses.prefix=t.cssClasses.formattedPrefix=r.formatPrefix(this.cssClasses.prefix,this.cssClasses.noPrefix),this.listboxId=t.listboxId=[this.cssClasses.root,"listbox",r.getUniqueId()].join("-");var s=function(t){var e,n,o,s;e=i.element(t.input),n=i.element(u.wrapper.replace("%ROOT%",t.cssClasses.root)).css(t.css.wrapper),t.appendTo||"block"!==e.css("display")||"table"!==e.parent().css("display")||n.css("display","table-cell");var a,c=u.dropdown.replace("%PREFIX%",t.cssClasses.prefix).replace("%DROPDOWN_MENU%",t.cssClasses.dropdownMenu);o=i.element(c).css(t.css.dropdown).attr({role:"listbox",id:t.listboxId}),t.templates&&t.templates.dropdownMenu&&o.html(r.templatify(t.templates.dropdownMenu)()),(s=e.clone().css(t.css.hint).css((a=e,{backgroundAttachment:a.css("background-attachment"),backgroundClip:a.css("background-clip"),backgroundColor:a.css("background-color"),backgroundImage:a.css("background-image"),backgroundOrigin:a.css("background-origin"),backgroundPosition:a.css("background-position"),backgroundRepeat:a.css("background-repeat"),backgroundSize:a.css("background-size")}))).val("").addClass(r.className(t.cssClasses.prefix,t.cssClasses.hint,!0)).removeAttr("id name placeholder required").prop("readonly",!0).attr({"aria-hidden":"true",autocomplete:"off",spellcheck:"false",tabindex:-1}),s.removeData&&s.removeData(),e.data("aaAttrs",{"aria-autocomplete":e.attr("aria-autocomplete"),"aria-expanded":e.attr("aria-expanded"),"aria-owns":e.attr("aria-owns"),autocomplete:e.attr("autocomplete"),dir:e.attr("dir"),role:e.attr("role"),spellcheck:e.attr("spellcheck"),style:e.attr("style"),type:e.attr("type")}),e.addClass(r.className(t.cssClasses.prefix,t.cssClasses.input,!0)).attr({autocomplete:"off",spellcheck:!1,role:"combobox","aria-autocomplete":t.datasets&&t.datasets[0]&&t.datasets[0].displayKey?"both":"list","aria-expanded":"false","aria-label":t.ariaLabel,"aria-owns":t.listboxId}).css(t.hint?t.css.input:t.css.inputWithNoHint);try{e.attr("dir")||e.attr("dir","auto")}catch(t){}return(n=t.appendTo?n.appendTo(i.element(t.appendTo).eq(0)).eq(0):e.wrap(n).parent()).prepend(t.hint?s:null).append(o),{wrapper:n,input:e,hint:s,menu:o}}(t);this.$node=s.wrapper;var a=this.$input=s.input;e=s.menu,n=s.hint,t.dropdownMenuContainer&&i.element(t.dropdownMenuContainer).css("position","relative").append(e.css("top","0")),a.on("blur.aa",(function(t){var n=document.activeElement;r.isMsie()&&(e[0]===n||e[0].contains(n))&&(t.preventDefault(),t.stopImmediatePropagation(),r.defer((function(){a.focus()})))})),e.on("mousedown.aa",(function(t){t.preventDefault()})),this.eventBus=t.eventBus||new o({el:a}),this.dropdown=new l.Dropdown({appendTo:t.appendTo,wrapper:this.$node,menu:e,datasets:t.datasets,templates:t.templates,cssClasses:t.cssClasses,minLength:this.minLength}).onSync("suggestionClicked",this._onSuggestionClicked,this).onSync("cursorMoved",this._onCursorMoved,this).onSync("cursorRemoved",this._onCursorRemoved,this).onSync("opened",this._onOpened,this).onSync("closed",this._onClosed,this).onSync("shown",this._onShown,this).onSync("empty",this._onEmpty,this).onSync("redrawn",this._onRedrawn,this).onAsync("datasetRendered",this._onDatasetRendered,this),this.input=new l.Input({input:a,hint:n}).onSync("focused",this._onFocused,this).onSync("blurred",this._onBlurred,this).onSync("enterKeyed",this._onEnterKeyed,this).onSync("tabKeyed",this._onTabKeyed,this).onSync("escKeyed",this._onEscKeyed,this).onSync("upKeyed",this._onUpKeyed,this).onSync("downKeyed",this._onDownKeyed,this).onSync("leftKeyed",this._onLeftKeyed,this).onSync("rightKeyed",this._onRightKeyed,this).onSync("queryChanged",this._onQueryChanged,this).onSync("whitespaceChanged",this._onWhitespaceChanged,this),this._bindKeyboardShortcuts(t),this._setLanguageDirection()}r.mixin(l.prototype,{_bindKeyboardShortcuts:function(t){if(t.keyboardShortcuts){var e=this.$input,n=[];r.each(t.keyboardShortcuts,(function(t){"string"==typeof t&&(t=t.toUpperCase().charCodeAt(0)),n.push(t)})),i.element(document).keydown((function(t){var r=t.target||t.srcElement,i=r.tagName;if(!r.isContentEditable&&"INPUT"!==i&&"SELECT"!==i&&"TEXTAREA"!==i){var o=t.which||t.keyCode;-1!==n.indexOf(o)&&(e.focus(),t.stopPropagation(),t.preventDefault())}}))}},_onSuggestionClicked:function(t,e){var n;(n=this.dropdown.getDatumForSuggestion(e))&&this._select(n)},_onCursorMoved:function(t,e){var n=this.dropdown.getDatumForCursor(),r=this.dropdown.getCurrentCursor().attr("id");this.input.setActiveDescendant(r),n&&(e&&this.input.setInputValue(n.value,!0),this.eventBus.trigger("cursorchanged",n.raw,n.datasetName))},_onCursorRemoved:function(){this.input.resetInputValue(),this._updateHint(),this.eventBus.trigger("cursorremoved")},_onDatasetRendered:function(){this._updateHint(),this.eventBus.trigger("updated")},_onOpened:function(){this._updateHint(),this.input.expand(),this.eventBus.trigger("opened")},_onEmpty:function(){this.eventBus.trigger("empty")},_onRedrawn:function(){this.$node.css("top","0px"),this.$node.css("left","0px");var t=this.$input[0].getBoundingClientRect();this.autoWidth&&this.$node.css("width",t.width+"px");var e=this.$node[0].getBoundingClientRect(),n=t.bottom-e.top;this.$node.css("top",n+"px");var r=t.left-e.left;this.$node.css("left",r+"px"),this.eventBus.trigger("redrawn")},_onShown:function(){this.eventBus.trigger("shown"),this.autoselect&&this.dropdown.cursorTopSuggestion()},_onClosed:function(){this.input.clearHint(),this.input.removeActiveDescendant(),this.input.collapse(),this.eventBus.trigger("closed")},_onFocused:function(){if(this.isActivated=!0,this.openOnFocus){var t=this.input.getQuery();t.length>=this.minLength?this.dropdown.update(t):this.dropdown.empty(),this.dropdown.open()}},_onBlurred:function(){var t,e;t=this.dropdown.getDatumForCursor(),e=this.dropdown.getDatumForTopSuggestion(),this.debug||(this.autoselectOnBlur&&t?this._select(t):this.autoselectOnBlur&&e?this._select(e):(this.isActivated=!1,this.dropdown.empty(),this.dropdown.close()))},_onEnterKeyed:function(t,e){var n,r;n=this.dropdown.getDatumForCursor(),r=this.dropdown.getDatumForTopSuggestion(),n?(this._select(n),e.preventDefault()):this.autoselect&&r&&(this._select(r),e.preventDefault())},_onTabKeyed:function(t,e){var n;this.tabAutocomplete?(n=this.dropdown.getDatumForCursor())?(this._select(n),e.preventDefault()):this._autocomplete(!0):this.dropdown.close()},_onEscKeyed:function(){this.dropdown.close(),this.input.resetInputValue()},_onUpKeyed:function(){var t=this.input.getQuery();this.dropdown.isEmpty&&t.length>=this.minLength?this.dropdown.update(t):this.dropdown.moveCursorUp(),this.dropdown.open()},_onDownKeyed:function(){var t=this.input.getQuery();this.dropdown.isEmpty&&t.length>=this.minLength?this.dropdown.update(t):this.dropdown.moveCursorDown(),this.dropdown.open()},_onLeftKeyed:function(){"rtl"===this.dir&&this._autocomplete()},_onRightKeyed:function(){"ltr"===this.dir&&this._autocomplete()},_onQueryChanged:function(t,e){this.input.clearHintIfInvalid(),e.length>=this.minLength?this.dropdown.update(e):this.dropdown.empty(),this.dropdown.open(),this._setLanguageDirection()},_onWhitespaceChanged:function(){this._updateHint(),this.dropdown.open()},_setLanguageDirection:function(){var t=this.input.getLanguageDirection();this.dir!==t&&(this.dir=t,this.$node.css("direction",t),this.dropdown.setLanguageDirection(t))},_updateHint:function(){var t,e,n,i,o;(t=this.dropdown.getDatumForTopSuggestion())&&this.dropdown.isVisible()&&!this.input.hasOverflow()?(e=this.input.getInputValue(),n=s.normalizeQuery(e),i=r.escapeRegExChars(n),(o=new RegExp("^(?:"+i+")(.+$)","i").exec(t.value))?this.input.setHint(e+o[1]):this.input.clearHint()):this.input.clearHint()},_autocomplete:function(t){var e,n,r,i;e=this.input.getHint(),n=this.input.getQuery(),r=t||this.input.isCursorAtEnd(),e&&n!==e&&r&&((i=this.dropdown.getDatumForTopSuggestion())&&this.input.setInputValue(i.value),this.eventBus.trigger("autocompleted",i.raw,i.datasetName))},_select:function(t){void 0!==t.value&&this.input.setQuery(t.value),this.clearOnSelected?this.setVal(""):this.input.setInputValue(t.value,!0),this._setLanguageDirection(),!1===this.eventBus.trigger("selected",t.raw,t.datasetName).isDefaultPrevented()&&(this.dropdown.close(),r.defer(r.bind(this.dropdown.empty,this.dropdown)))},open:function(){if(!this.isActivated){var t=this.input.getInputValue();t.length>=this.minLength?this.dropdown.update(t):this.dropdown.empty()}this.dropdown.open()},close:function(){this.dropdown.close()},setVal:function(t){t=r.toStr(t),this.isActivated?this.input.setInputValue(t):(this.input.setQuery(t),this.input.setInputValue(t,!0)),this._setLanguageDirection()},getVal:function(){return this.input.getQuery()},destroy:function(){var t,e,n;this.input.destroy(),this.dropdown.destroy(),t=this.$node,e=this.cssClasses,n=t.find(r.className(e.prefix,e.input)),r.each(n.data("aaAttrs"),(function(t,e){void 0===t?n.removeAttr(e):n.attr(e,t)})),n.detach().removeClass(r.className(e.prefix,e.input,!0)).insertAfter(t),n.removeData&&n.removeData("aaAttrs"),t.remove(),this.$node=null},getWrapper:function(){return this.dropdown.$container[0]}}),l.Dropdown=a,l.Input=s,l.sources=n(61),t.exports=l},function(t,e,n){"use strict";var r;r={9:"tab",27:"esc",37:"left",39:"right",13:"enter",38:"up",40:"down"};var i=n(0),o=n(1),s=n(10);function a(t){var e,n,s,a,u,c=this;(t=t||{}).input||i.error("input is missing"),e=i.bind(this._onBlur,this),n=i.bind(this._onFocus,this),s=i.bind(this._onKeydown,this),a=i.bind(this._onInput,this),this.$hint=o.element(t.hint),this.$input=o.element(t.input).on("blur.aa",e).on("focus.aa",n).on("keydown.aa",s),0===this.$hint.length&&(this.setHint=this.getHint=this.clearHint=this.clearHintIfInvalid=i.noop),i.isMsie()?this.$input.on("keydown.aa keypress.aa cut.aa paste.aa",(function(t){r[t.which||t.keyCode]||i.defer(i.bind(c._onInput,c,t))})):this.$input.on("input.aa",a),this.query=this.$input.val(),this.$overflowHelper=(u=this.$input,o.element('<pre aria-hidden="true"></pre>').css({position:"absolute",visibility:"hidden",whiteSpace:"pre",fontFamily:u.css("font-family"),fontSize:u.css("font-size"),fontStyle:u.css("font-style"),fontVariant:u.css("font-variant"),fontWeight:u.css("font-weight"),wordSpacing:u.css("word-spacing"),letterSpacing:u.css("letter-spacing"),textIndent:u.css("text-indent"),textRendering:u.css("text-rendering"),textTransform:u.css("text-transform")}).insertAfter(u))}function u(t){return t.altKey||t.ctrlKey||t.metaKey||t.shiftKey}a.normalizeQuery=function(t){return(t||"").replace(/^\s*/g,"").replace(/\s{2,}/g," ")},i.mixin(a.prototype,s,{_onBlur:function(){this.resetInputValue(),this.$input.removeAttr("aria-activedescendant"),this.trigger("blurred")},_onFocus:function(){this.trigger("focused")},_onKeydown:function(t){var e=r[t.which||t.keyCode];this._managePreventDefault(e,t),e&&this._shouldTrigger(e,t)&&this.trigger(e+"Keyed",t)},_onInput:function(){this._checkInputValue()},_managePreventDefault:function(t,e){var n,r,i;switch(t){case"tab":r=this.getHint(),i=this.getInputValue(),n=r&&r!==i&&!u(e);break;case"up":case"down":n=!u(e);break;default:n=!1}n&&e.preventDefault()},_shouldTrigger:function(t,e){var n;switch(t){case"tab":n=!u(e);break;default:n=!0}return n},_checkInputValue:function(){var t,e,n,r,i;t=this.getInputValue(),r=t,i=this.query,n=!(!(e=a.normalizeQuery(r)===a.normalizeQuery(i))||!this.query)&&this.query.length!==t.length,this.query=t,e?n&&this.trigger("whitespaceChanged",this.query):this.trigger("queryChanged",this.query)},focus:function(){this.$input.focus()},blur:function(){this.$input.blur()},getQuery:function(){return this.query},setQuery:function(t){this.query=t},getInputValue:function(){return this.$input.val()},setInputValue:function(t,e){void 0===t&&(t=this.query),this.$input.val(t),e?this.clearHint():this._checkInputValue()},expand:function(){this.$input.attr("aria-expanded","true")},collapse:function(){this.$input.attr("aria-expanded","false")},setActiveDescendant:function(t){this.$input.attr("aria-activedescendant",t)},removeActiveDescendant:function(){this.$input.removeAttr("aria-activedescendant")},resetInputValue:function(){this.setInputValue(this.query,!0)},getHint:function(){return this.$hint.val()},setHint:function(t){this.$hint.val(t)},clearHint:function(){this.setHint("")},clearHintIfInvalid:function(){var t,e,n;n=(t=this.getInputValue())!==(e=this.getHint())&&0===e.indexOf(t),""!==t&&n&&!this.hasOverflow()||this.clearHint()},getLanguageDirection:function(){return(this.$input.css("direction")||"ltr").toLowerCase()},hasOverflow:function(){var t=this.$input.width()-2;return this.$overflowHelper.text(this.getInputValue()),this.$overflowHelper.width()>=t},isCursorAtEnd:function(){var t,e,n;return t=this.$input.val().length,e=this.$input[0].selectionStart,i.isNumber(e)?e===t:!document.selection||((n=document.selection.createRange()).moveStart("character",-t),t===n.text.length)},destroy:function(){this.$hint.off(".aa"),this.$input.off(".aa"),this.$hint=this.$input=this.$overflowHelper=null}}),t.exports=a},function(t,e,n){"use strict";var r,i,o,s=[n(54),n(55),n(56),n(57),n(58)],a=-1,u=[],c=!1;function l(){r&&i&&(r=!1,i.length?u=i.concat(u):a=-1,u.length&&h())}function h(){if(!r){c=!1,r=!0;for(var t=u.length,e=setTimeout(l);t;){for(i=u,u=[];i&&++a<t;)i[a].run();a=-1,t=u.length}i=null,a=-1,r=!1,clearTimeout(e)}}for(var f=-1,d=s.length;++f<d;)if(s[f]&&s[f].test&&s[f].test()){o=s[f].install(h);break}function p(t,e){this.fun=t,this.array=e}p.prototype.run=function(){var t=this.fun,e=this.array;switch(e.length){case 0:return t();case 1:return t(e[0]);case 2:return t(e[0],e[1]);case 3:return t(e[0],e[1],e[2]);default:return t.apply(null,e)}},t.exports=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];u.push(new p(t,e)),c||r||(c=!0,o())}},function(t,e,n){"use strict";(function(t){e.test=function(){return void 0!==t&&!t.browser},e.install=function(e){return function(){t.nextTick(e)}}}).call(e,n(9))},function(t,e,n){"use strict";(function(t){var n=t.MutationObserver||t.WebKitMutationObserver;e.test=function(){return n},e.install=function(e){var r=0,i=new n(e),o=t.document.createTextNode("");return i.observe(o,{characterData:!0}),function(){o.data=r=++r%2}}}).call(e,n(4))},function(t,e,n){"use strict";(function(t){e.test=function(){return!t.setImmediate&&void 0!==t.MessageChannel},e.install=function(e){var n=new t.MessageChannel;return n.port1.onmessage=e,function(){n.port2.postMessage(0)}}}).call(e,n(4))},function(t,e,n){"use strict";(function(t){e.test=function(){return"document"in t&&"onreadystatechange"in t.document.createElement("script")},e.install=function(e){return function(){var n=t.document.createElement("script");return n.onreadystatechange=function(){e(),n.onreadystatechange=null,n.parentNode.removeChild(n),n=null},t.document.documentElement.appendChild(n),e}}}).call(e,n(4))},function(t,e,n){"use strict";e.test=function(){return!0},e.install=function(t){return function(){setTimeout(t,0)}}},function(t,e,n){"use strict";var r=n(0),i=n(1),o=n(10),s=n(60),a=n(11);function u(t){var e,n,o,s=this;(t=t||{}).menu||r.error("menu is required"),r.isArray(t.datasets)||r.isObject(t.datasets)||r.error("1 or more datasets required"),t.datasets||r.error("datasets is required"),this.isOpen=!1,this.isEmpty=!0,this.minLength=t.minLength||0,this.templates={},this.appendTo=t.appendTo||!1,this.css=r.mixin({},a,t.appendTo?a.appendTo:{}),this.cssClasses=t.cssClasses=r.mixin({},a.defaultClasses,t.cssClasses||{}),this.cssClasses.prefix=t.cssClasses.formattedPrefix||r.formatPrefix(this.cssClasses.prefix,this.cssClasses.noPrefix),e=r.bind(this._onSuggestionClick,this),n=r.bind(this._onSuggestionMouseEnter,this),o=r.bind(this._onSuggestionMouseLeave,this);var c=r.className(this.cssClasses.prefix,this.cssClasses.suggestion);this.$menu=i.element(t.menu).on("mouseenter.aa",c,n).on("mouseleave.aa",c,o).on("click.aa",c,e),this.$container=t.appendTo?t.wrapper:this.$menu,t.templates&&t.templates.header&&(this.templates.header=r.templatify(t.templates.header),this.$menu.prepend(this.templates.header())),t.templates&&t.templates.empty&&(this.templates.empty=r.templatify(t.templates.empty),this.$empty=i.element('<div class="'+r.className(this.cssClasses.prefix,this.cssClasses.empty,!0)+'"></div>'),this.$menu.append(this.$empty),this.$empty.hide()),this.datasets=r.map(t.datasets,(function(e){return function(t,e,n){return new u.Dataset(r.mixin({$menu:t,cssClasses:n},e))}(s.$menu,e,t.cssClasses)})),r.each(this.datasets,(function(t){var e=t.getRoot();e&&0===e.parent().length&&s.$menu.append(e),t.onSync("rendered",s._onRendered,s)})),t.templates&&t.templates.footer&&(this.templates.footer=r.templatify(t.templates.footer),this.$menu.append(this.templates.footer()));var l=this;i.element(window).resize((function(){l._redraw()}))}r.mixin(u.prototype,o,{_onSuggestionClick:function(t){this.trigger("suggestionClicked",i.element(t.currentTarget))},_onSuggestionMouseEnter:function(t){var e=i.element(t.currentTarget);if(!e.hasClass(r.className(this.cssClasses.prefix,this.cssClasses.cursor,!0))){this._removeCursor();var n=this;setTimeout((function(){n._setCursor(e,!1)}),0)}},_onSuggestionMouseLeave:function(t){t.relatedTarget&&i.element(t.relatedTarget).closest("."+r.className(this.cssClasses.prefix,this.cssClasses.cursor,!0)).length>0||(this._removeCursor(),this.trigger("cursorRemoved"))},_onRendered:function(t,e){if(this.isEmpty=r.every(this.datasets,(function(t){return t.isEmpty()})),this.isEmpty)if(e.length>=this.minLength&&this.trigger("empty"),this.$empty)if(e.length<this.minLength)this._hide();else{var n=this.templates.empty({query:this.datasets[0]&&this.datasets[0].query});this.$empty.html(n),this.$empty.show(),this._show()}else r.any(this.datasets,(function(t){return t.templates&&t.templates.empty}))?e.length<this.minLength?this._hide():this._show():this._hide();else this.isOpen&&(this.$empty&&(this.$empty.empty(),this.$empty.hide()),e.length>=this.minLength?this._show():this._hide());this.trigger("datasetRendered")},_hide:function(){this.$container.hide()},_show:function(){this.$container.css("display","block"),this._redraw(),this.trigger("shown")},_redraw:function(){this.isOpen&&this.appendTo&&this.trigger("redrawn")},_getSuggestions:function(){return this.$menu.find(r.className(this.cssClasses.prefix,this.cssClasses.suggestion))},_getCursor:function(){return this.$menu.find(r.className(this.cssClasses.prefix,this.cssClasses.cursor)).first()},_setCursor:function(t,e){t.first().addClass(r.className(this.cssClasses.prefix,this.cssClasses.cursor,!0)).attr("aria-selected","true"),this.trigger("cursorMoved",e)},_removeCursor:function(){this._getCursor().removeClass(r.className(this.cssClasses.prefix,this.cssClasses.cursor,!0)).removeAttr("aria-selected")},_moveCursor:function(t){var e,n,r,i;this.isOpen&&(n=this._getCursor(),e=this._getSuggestions(),this._removeCursor(),-1!=(r=((r=e.index(n)+t)+1)%(e.length+1)-1)?(r<-1&&(r=e.length-1),this._setCursor(i=e.eq(r),!0),this._ensureVisible(i)):this.trigger("cursorRemoved"))},_ensureVisible:function(t){var e,n,r,i;n=(e=t.position().top)+t.height()+parseInt(t.css("margin-top"),10)+parseInt(t.css("margin-bottom"),10),r=this.$menu.scrollTop(),i=this.$menu.height()+parseInt(this.$menu.css("padding-top"),10)+parseInt(this.$menu.css("padding-bottom"),10),e<0?this.$menu.scrollTop(r+e):i<n&&this.$menu.scrollTop(r+(n-i))},close:function(){this.isOpen&&(this.isOpen=!1,this._removeCursor(),this._hide(),this.trigger("closed"))},open:function(){this.isOpen||(this.isOpen=!0,this.isEmpty||this._show(),this.trigger("opened"))},setLanguageDirection:function(t){this.$menu.css("ltr"===t?this.css.ltr:this.css.rtl)},moveCursorUp:function(){this._moveCursor(-1)},moveCursorDown:function(){this._moveCursor(1)},getDatumForSuggestion:function(t){var e=null;return t.length&&(e={raw:s.extractDatum(t),value:s.extractValue(t),datasetName:s.extractDatasetName(t)}),e},getCurrentCursor:function(){return this._getCursor().first()},getDatumForCursor:function(){return this.getDatumForSuggestion(this._getCursor().first())},getDatumForTopSuggestion:function(){return this.getDatumForSuggestion(this._getSuggestions().first())},cursorTopSuggestion:function(){this._setCursor(this._getSuggestions().first(),!1)},update:function(t){r.each(this.datasets,(function(e){e.update(t)}))},empty:function(){r.each(this.datasets,(function(t){t.clear()})),this.isEmpty=!0},isVisible:function(){return this.isOpen&&!this.isEmpty},destroy:function(){this.$menu.off(".aa"),this.$menu=null,r.each(this.datasets,(function(t){t.destroy()}))}}),u.Dataset=s,t.exports=u},function(t,e,n){"use strict";var r=n(0),i=n(1),o=n(17),s=n(11),a=n(10);function u(t){var e,n,a,u;(t=t||{}).templates=t.templates||{},t.source||r.error("missing source"),t.name&&(e=t.name,!/^[_a-zA-Z0-9-]+$/.test(e))&&r.error("invalid dataset name: "+t.name),this.query=null,this._isEmpty=!0,this.highlight=!!t.highlight,this.name=void 0===t.name||null===t.name?r.getUniqueId():t.name,this.source=t.source,this.displayFn=(n=(n=t.display||t.displayKey)||"value",r.isFunction(n)?n:function(t){return t[n]}),this.debounce=t.debounce,this.cache=!1!==t.cache,this.templates=(a=t.templates,u=this.displayFn,{empty:a.empty&&r.templatify(a.empty),header:a.header&&r.templatify(a.header),footer:a.footer&&r.templatify(a.footer),suggestion:a.suggestion||function(t){return"<p>"+u(t)+"</p>"}}),this.css=r.mixin({},s,t.appendTo?s.appendTo:{}),this.cssClasses=t.cssClasses=r.mixin({},s.defaultClasses,t.cssClasses||{}),this.cssClasses.prefix=t.cssClasses.formattedPrefix||r.formatPrefix(this.cssClasses.prefix,this.cssClasses.noPrefix);var c=r.className(this.cssClasses.prefix,this.cssClasses.dataset);this.$el=t.$menu&&t.$menu.find(c+"-"+this.name).length>0?i.element(t.$menu.find(c+"-"+this.name)[0]):i.element(o.dataset.replace("%CLASS%",this.name).replace("%PREFIX%",this.cssClasses.prefix).replace("%DATASET%",this.cssClasses.dataset)),this.$menu=t.$menu,this.clearCachedSuggestions()}u.extractDatasetName=function(t){return i.element(t).data("aaDataset")},u.extractValue=function(t){return i.element(t).data("aaValue")},u.extractDatum=function(t){var e=i.element(t).data("aaDatum");return"string"==typeof e&&(e=JSON.parse(e)),e},r.mixin(u.prototype,a,{_render:function(t,e){if(this.$el){var n,s=this,a=[].slice.call(arguments,2);if(this.$el.empty(),n=e&&e.length,this._isEmpty=!n,!n&&this.templates.empty)this.$el.html(u.apply(this,a)).prepend(s.templates.header?l.apply(this,a):null).append(s.templates.footer?h.apply(this,a):null);else if(n)this.$el.html(c.apply(this,a)).prepend(s.templates.header?l.apply(this,a):null).append(s.templates.footer?h.apply(this,a):null);else if(e&&!Array.isArray(e))throw new TypeError("suggestions must be an array");this.$menu&&this.$menu.addClass(this.cssClasses.prefix+(n?"with":"without")+"-"+this.name).removeClass(this.cssClasses.prefix+(n?"without":"with")+"-"+this.name),this.trigger("rendered",t)}function u(){var e=[].slice.call(arguments,0);return e=[{query:t,isEmpty:!0}].concat(e),s.templates.empty.apply(this,e)}function c(){var t,n,a=[].slice.call(arguments,0),u=this,c=o.suggestions.replace("%PREFIX%",this.cssClasses.prefix).replace("%SUGGESTIONS%",this.cssClasses.suggestions);return t=i.element(c).css(this.css.suggestions),n=r.map(e,l),t.append.apply(t,n),t;function l(t){var e,n=o.suggestion.replace("%PREFIX%",u.cssClasses.prefix).replace("%SUGGESTION%",u.cssClasses.suggestion);return(e=i.element(n).attr({role:"option",id:["option",Math.floor(1e8*Math.random())].join("-")}).append(s.templates.suggestion.apply(this,[t].concat(a)))).data("aaDataset",s.name),e.data("aaValue",s.displayFn(t)||void 0),e.data("aaDatum",JSON.stringify(t)),e.children().each((function(){i.element(this).css(u.css.suggestionChild)})),e}}function l(){var e=[].slice.call(arguments,0);return e=[{query:t,isEmpty:!n}].concat(e),s.templates.header.apply(this,e)}function h(){var e=[].slice.call(arguments,0);return e=[{query:t,isEmpty:!n}].concat(e),s.templates.footer.apply(this,e)}},getRoot:function(){return this.$el},update:function(t){function e(e){if(!this.canceled&&t===this.query){var n=[].slice.call(arguments,1);this.cacheSuggestions(t,e,n),this._render.apply(this,[t,e].concat(n))}}if(this.query=t,this.canceled=!1,this.shouldFetchFromCache(t))e.apply(this,[this.cachedSuggestions].concat(this.cachedRenderExtraArgs));else{var n=this,r=function(){n.canceled||n.source(t,e.bind(n))};this.debounce?(clearTimeout(this.debounceTimeout),this.debounceTimeout=setTimeout((function(){n.debounceTimeout=null,r()}),this.debounce)):r()}},cacheSuggestions:function(t,e,n){this.cachedQuery=t,this.cachedSuggestions=e,this.cachedRenderExtraArgs=n},shouldFetchFromCache:function(t){return this.cache&&this.cachedQuery===t&&this.cachedSuggestions&&this.cachedSuggestions.length},clearCachedSuggestions:function(){delete this.cachedQuery,delete this.cachedSuggestions,delete this.cachedRenderExtraArgs},cancel:function(){this.canceled=!0},clear:function(){this.cancel(),this.$el.empty(),this.trigger("rendered","")},isEmpty:function(){return this._isEmpty},destroy:function(){this.clearCachedSuggestions(),this.$el=null}}),t.exports=u},function(t,e,n){"use strict";t.exports={hits:n(62),popularIn:n(63)}},function(t,e,n){"use strict";var r=n(0),i=n(18),o=n(19);t.exports=function(t,e){var n=o(t.as._ua);return n&&n[0]>=3&&n[1]>20&&((e=e||{}).additionalUA="autocomplete.js "+i),function(n,i){t.search(n,e,(function(t,e){t?r.error(t.message):i(e.hits,e)}))}}},function(t,e,n){"use strict";var r=n(0),i=n(18),o=n(19);t.exports=function(t,e,n,s){var a=o(t.as._ua);if(a&&a[0]>=3&&a[1]>20&&((e=e||{}).additionalUA="autocomplete.js "+i),!n.source)return r.error("Missing 'source' key");var u=r.isFunction(n.source)?n.source:function(t){return t[n.source]};if(!n.index)return r.error("Missing 'index' key");var c=n.index;return s=s||{},function(a,l){t.search(a,e,(function(t,a){if(t)r.error(t.message);else{if(a.hits.length>0){var h=a.hits[0],f=r.mixin({hitsPerPage:0},n);delete f.source,delete f.index;var d=o(c.as._ua);return d&&d[0]>=3&&d[1]>20&&(e.additionalUA="autocomplete.js "+i),void c.search(u(h),f,(function(t,e){if(t)r.error(t.message);else{var n=[];if(s.includeAll){var i=s.allTitle||"All departments";n.push(r.mixin({facet:{value:i,count:e.nbHits}},r.cloneDeep(h)))}r.each(e.facets,(function(t,e){r.each(t,(function(t,i){n.push(r.mixin({facet:{facet:e,value:i,count:t}},r.cloneDeep(h)))}))}));for(var o=1;o<a.hits.length;++o)n.push(a.hits[o]);l(n,a)}}))}l([])}}))}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r="algolia-docsearch-suggestion",i={suggestion:'\n <a class="'+r+"\n {{#isCategoryHeader}}"+r+"__main{{/isCategoryHeader}}\n {{#isSubCategoryHeader}}"+r+'__secondary{{/isSubCategoryHeader}}\n "\n aria-label="Link to the result"\n href="{{{url}}}"\n >\n <div class="'+r+'--category-header">\n <span class="'+r+'--category-header-lvl0">{{{category}}}</span>\n </div>\n <div class="'+r+'--wrapper">\n <div class="'+r+'--subcategory-column">\n <span class="'+r+'--subcategory-column-text">{{{subcategory}}}</span>\n </div>\n {{#isTextOrSubcategoryNonEmpty}}\n <div class="'+r+'--content">\n <div class="'+r+'--subcategory-inline">{{{subcategory}}}</div>\n <div class="'+r+'--title">{{{title}}}</div>\n {{#text}}<div class="'+r+'--text">{{{text}}}</div>{{/text}}\n </div>\n {{/isTextOrSubcategoryNonEmpty}}\n </div>\n </a>\n ',suggestionSimple:'\n <div class="'+r+"\n {{#isCategoryHeader}}"+r+"__main{{/isCategoryHeader}}\n {{#isSubCategoryHeader}}"+r+'__secondary{{/isSubCategoryHeader}}\n suggestion-layout-simple\n ">\n <div class="'+r+'--category-header">\n {{^isLvl0}}\n <span class="'+r+"--category-header-lvl0 "+r+'--category-header-item">{{{category}}}</span>\n {{^isLvl1}}\n {{^isLvl1EmptyOrDuplicate}}\n <span class="'+r+"--category-header-lvl1 "+r+'--category-header-item">\n {{{subcategory}}}\n </span>\n {{/isLvl1EmptyOrDuplicate}}\n {{/isLvl1}}\n {{/isLvl0}}\n <div class="'+r+"--title "+r+'--category-header-item">\n {{#isLvl2}}\n {{{title}}}\n {{/isLvl2}}\n {{#isLvl1}}\n {{{subcategory}}}\n {{/isLvl1}}\n {{#isLvl0}}\n {{{category}}}\n {{/isLvl0}}\n </div>\n </div>\n <div class="'+r+'--wrapper">\n {{#text}}\n <div class="'+r+'--content">\n <div class="'+r+'--text">{{{text}}}</div>\n </div>\n {{/text}}\n </div>\n </div>\n ',footer:'\n <div class="algolia-docsearch-footer">\n Search by <a class="algolia-docsearch-footer--logo" href="https://www.algolia.com/docsearch">Algolia</a>\n </div>\n ',empty:'\n <div class="'+r+'">\n <div class="'+r+'--wrapper">\n <div class="'+r+"--content "+r+'--no-results">\n <div class="'+r+'--title">\n <div class="'+r+'--text">\n No results found for query <b>"{{query}}"</b>\n </div>\n </div>\n </div>\n </div>\n </div>\n ',searchBox:'\n <form novalidate="novalidate" onsubmit="return false;" class="searchbox">\n <div role="search" class="searchbox__wrapper">\n <input id="docsearch" type="search" name="search" placeholder="Search the docs" autocomplete="off" required="required" class="searchbox__input"/>\n <button type="submit" title="Submit your search query." class="searchbox__submit" >\n <svg width=12 height=12 role="img" aria-label="Search">\n <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#sbx-icon-search-13"></use>\n </svg>\n </button>\n <button type="reset" title="Clear the search query." class="searchbox__reset hide">\n <svg width=12 height=12 role="img" aria-label="Reset">\n <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#sbx-icon-clear-3"></use>\n </svg>\n </button>\n </div>\n</form>\n\n<div class="svg-icons" style="height: 0; width: 0; position: absolute; visibility: hidden">\n <svg xmlns="http://www.w3.org/2000/svg">\n <symbol id="sbx-icon-clear-3" viewBox="0 0 40 40"><path d="M16.228 20L1.886 5.657 0 3.772 3.772 0l1.885 1.886L20 16.228 34.343 1.886 36.228 0 40 3.772l-1.886 1.885L23.772 20l14.342 14.343L40 36.228 36.228 40l-1.885-1.886L20 23.772 5.657 38.114 3.772 40 0 36.228l1.886-1.885L16.228 20z" fill-rule="evenodd"></symbol>\n <symbol id="sbx-icon-search-13" viewBox="0 0 40 40"><path d="M26.806 29.012a16.312 16.312 0 0 1-10.427 3.746C7.332 32.758 0 25.425 0 16.378 0 7.334 7.333 0 16.38 0c9.045 0 16.378 7.333 16.378 16.38 0 3.96-1.406 7.593-3.746 10.426L39.547 37.34c.607.608.61 1.59-.004 2.203a1.56 1.56 0 0 1-2.202.004L26.807 29.012zm-10.427.627c7.322 0 13.26-5.938 13.26-13.26 0-7.324-5.938-13.26-13.26-13.26-7.324 0-13.26 5.936-13.26 13.26 0 7.322 5.936 13.26 13.26 13.26z" fill-rule="evenodd"></symbol>\n </svg>\n</div>\n '};e.default=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o=n(20),s=(r=o)&&r.__esModule?r:{default:r},a={mergeKeyWithParent:function(t,e){if(void 0===t[e])return t;if("object"!==i(t[e]))return t;var n=s.default.extend({},t,t[e]);return delete n[e],n},groupBy:function(t,e){var n={};return s.default.each(t,(function(t,r){if(void 0===r[e])throw new Error("[groupBy]: Object has no key "+e);var i=r[e];"string"==typeof i&&(i=i.toLowerCase()),Object.prototype.hasOwnProperty.call(n,i)||(n[i]=[]),n[i].push(r)})),n},values:function(t){return Object.keys(t).map((function(e){return t[e]}))},flatten:function(t){var e=[];return t.forEach((function(t){Array.isArray(t)?t.forEach((function(t){e.push(t)})):e.push(t)})),e},flattenAndFlagFirst:function(t,e){var n=this.values(t).map((function(t){return t.map((function(t,n){return t[e]=0===n,t}))}));return this.flatten(n)},compact:function(t){var e=[];return t.forEach((function(t){t&&e.push(t)})),e},getHighlightedValue:function(t,e){return t._highlightResult&&t._highlightResult.hierarchy_camel&&t._highlightResult.hierarchy_camel[e]&&t._highlightResult.hierarchy_camel[e].matchLevel&&"none"!==t._highlightResult.hierarchy_camel[e].matchLevel&&t._highlightResult.hierarchy_camel[e].value?t._highlightResult.hierarchy_camel[e].value:t._highlightResult&&t._highlightResult&&t._highlightResult[e]&&t._highlightResult[e].value?t._highlightResult[e].value:t[e]},getSnippetedValue:function(t,e){if(!t._snippetResult||!t._snippetResult[e]||!t._snippetResult[e].value)return t[e];var n=t._snippetResult[e].value;return n[0]!==n[0].toUpperCase()&&(n="…"+n),-1===[".","!","?"].indexOf(n[n.length-1])&&(n+="…"),n},deepClone:function(t){return JSON.parse(JSON.stringify(t))}};e.default=a}])},t.exports=r()},function(t,e,n){n(0),n(10)},function(t,e,n){!function(e,r){var i=function(){r(e.lazySizes),e.removeEventListener("lazyunveilread",i,!0)};r=r.bind(null,e,e.document),t.exports?r(n(0)):e.lazySizes?i():e.addEventListener("lazyunveilread",i,!0)}(window,(function(t,e,n){"use strict";var r,i,o={};function s(t,n){if(!o[t]){var r=e.createElement(n?"link":"script"),i=e.getElementsByTagName("script")[0];n?(r.rel="stylesheet",r.href=t):r.src=t,o[t]=!0,o[r.src||r.href]=!0,i.parentNode.insertBefore(r,i)}}e.addEventListener&&(i=/\(|\)|\s|'/,r=function(t,n){var r=e.createElement("img");r.onload=function(){r.onload=null,r.onerror=null,r=null,n()},r.onerror=r.onload,r.src=t,r&&r.complete&&r.onload&&r.onload()},addEventListener("lazybeforeunveil",(function(t){var e,o,a;t.detail.instance==n&&(t.defaultPrevented||("none"==t.target.preload&&(t.target.preload="auto"),(e=t.target.getAttribute("data-link"))&&s(e,!0),(e=t.target.getAttribute("data-script"))&&s(e),(e=t.target.getAttribute("data-require"))&&(n.cfg.requireJs?n.cfg.requireJs([e]):s(e)),(o=t.target.getAttribute("data-bg"))&&(t.detail.firesLoad=!0,r(o,(function(){t.target.style.backgroundImage="url("+(i.test(o)?JSON.stringify(o):o)+")",t.detail.firesLoad=!1,n.fire(t.target,"_lazyloaded",{},!0,!0)}))),(a=t.target.getAttribute("data-poster"))&&(t.detail.firesLoad=!0,r(a,(function(){t.target.poster=a,t.detail.firesLoad=!1,n.fire(t.target,"_lazyloaded",{},!0,!0)})))))}),!1))}))},function(t,e){for(var n=document.getElementsByClassName("js-toggle"),r=0;r<n.length;r++)n[r].addEventListener("click",i,!1);function i(){for(var t=this.dataset.target.split(" "),e=document.querySelector(".mobilemenu:not(.dn)"),n=document.querySelector(".desktopmenu:not(.dn)"),r=document.querySelector(".desktopmenu:not(.dn)"),i=0;i<t.length;i++){var o=document.querySelectorAll(t[i]);[].forEach.call(o,(function(t){return t.classList.contains("dn")?t.classList.remove("dn"):t.classList.add("dn"),!1})),e&&e.classList.add("dn"),n&&n.classList.add("dn"),r&&r.classList.remove("db")}}},function(t,e,n){n(13)},function(t,e,n){!function(){"use strict";var t,e,n="data-scrolldir",r="down",i=document.documentElement,o=window,s=document.body,a=Array(32),u=0;function c(){var c=o.scrollY||o.pageYOffset,l=t.timeStamp,h="down"===r?Math.max:Math.min,f=s.scrollHeight-o.innerHeight;if(c=Math.max(0,c),c=Math.min(f,c),a.unshift({y:c,t:l}),a.pop(),c===h(e,c))return u=l,void(e=c);var d=l-512;if(u<d){e=c;for(var p=0;p<32&&a[p]&&!(a[p].t<d);p+=1)e=h(e,a[p].y)}Math.abs(c-e)>64&&(e=c,u=l,r="down"===r?"up":"down",i.setAttribute(n,r))}function l(e){return t=e,o.requestAnimationFrame(c)}e=o.scrollY||o.pageYOffset,i.setAttribute(n,r),o.addEventListener("scroll",l)}()},function(t,e){!function(){"use strict";if("querySelector"in document&&"addEventListener"in window&&Array.prototype.forEach){var t=document.querySelectorAll("#TableOfContents ul li a");[].forEach.call(t,(function(t){t.addEventListener("click",(function(e){e.preventDefault();var n=t.getAttribute("href"),r=document.querySelector(n),i=t.getAttribute("data-speed");r&&function(t,e){var n,r=window.pageYOffset,i=t.offsetTop,o=(i-r)/(e/16);n=o>=0?function(){var t=window.pageYOffset;(t>=i-o||window.innerHeight+t>=document.body.offsetHeight)&&clearInterval(s)}:function(){window.pageYOffset<=(i||0)&&clearInterval(s)};var s=setInterval((function(){window.scrollBy(0,o),n()}),16)}(r,i||500)}),!1)}))}}()},function(t,e){var n,r=document.querySelectorAll("[data-toggle-tab]"),i=document.querySelectorAll("[data-pane]");function o(t){if(t.target){t.preventDefault();var e=t.currentTarget.getAttribute("data-toggle-tab")}else e=t;window.localStorage&&window.localStorage.setItem("configLangPref",e);for(var n=document.querySelectorAll("[data-toggle-tab='"+e+"']"),o=document.querySelectorAll("[data-pane='"+e+"']"),s=0;s<r.length;s++)r[s].classList.remove("active"),i[s].classList.remove("active");for(s=0;s<n.length;s++)n[s].classList.add("active"),o[s].classList.add("active")}for(n=0;n<r.length;n++)r[n].addEventListener("click",o);window.localStorage.getItem("configLangPref")&&o(window.localStorage.getItem("configLangPref"))},function(t,e){document.documentElement.className=document.documentElement.className.replace(/\bno-js\b/,"js")}]); \ No newline at end of file
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/data/sponsors.toml b/_vendor/github.com/gohugoio/gohugoioTheme/data/sponsors.toml
index 0d276b374..1e46fc07c 100644
--- a/_vendor/github.com/gohugoio/gohugoioTheme/data/sponsors.toml
+++ b/_vendor/github.com/gohugoio/gohugoioTheme/data/sponsors.toml
@@ -1,18 +1,22 @@
[[banners]]
- name = "Linode"
- link = "https://www.linode.com/"
- logo = "/images/sponsors/linode-logo_standard_light_medium.png"
- copy = ""
+ name = "Linode"
+ link = "https://www.linode.com/"
+ logo = "/images/sponsors/linode-logo_standard_light_medium.png"
+ utm_campaign = "hugosponsor"
[[banners]]
- name = "eSolia"
- link = "https://esolia.com/post/why-did-esolia-choose-hugo/"
- logo = "/images/sponsors/esolia-logo.svg"
- copy = ""
+ name = "eSolia"
+ link = "https://esolia.com/post/why-did-esolia-choose-hugo/"
+ logo = "/images/sponsors/esolia-logo.svg"
+ utm_campaign = "hugosponsor"
[[banners]]
- name = "BEP Consulting"
- link = "https://bep.consulting"
- logo = "/images/sponsors/bep-consulting.svg"
- bgcolor = "#004887"
- copy = ""
+ name = "ButterCMS"
+ link = "https://buttercms.com/hugo-cms/"
+ logo = "/images/sponsors/butter-light.svg"
+ utm_campaign = "sponsorship"
+ bgcolor = "#131A3E"
+
+ #hugohome
+ #hugofooter
+ #hugogithub
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/partials/home-page-sections/sponsors.html b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/partials/home-page-sections/sponsors.html
index a808655a6..e0f6670be 100644
--- a/_vendor/github.com/gohugoio/gohugoioTheme/layouts/partials/home-page-sections/sponsors.html
+++ b/_vendor/github.com/gohugoio/gohugoioTheme/layouts/partials/home-page-sections/sponsors.html
@@ -1,38 +1,41 @@
-{{$classes_box := "ba b--dark-gray bg-light-gray br3 flex flex-column flex-wrap items-center justify-center ph3 pv4 mb4 w-100 w-30-l "}}
-{{$gtag := .gtag | default "unknown" }}
+{{ $classes_box := "ba b--dark-gray bg-light-gray br3 flex flex-column flex-wrap items-center justify-center ph3 pv4 mb4 w-100 w-30-l " }}
+{{ $gtag := .gtag | default "unknown" }}
+{{ $classes_box := "ba b--dark-gray bg-light-gray br3 flex flex-column flex-wrap items-center justify-center ph3 pv4 mb4 w-100 w-30-l " }}
+{{ $gtag := .gtag | default "unknown" }}
+{{ $utmSource := cond (eq $gtag "footer") "hugofooter" "hugohome" }}
{{ with .cx.Site.Data.sponsors }}
- <section class="{{ $.classes_section | default "bg-primary-color-dark b--dark-gray bb bt ph5 pv4 w-100"}}">
- <div class="center mw9"> 
+ <section
+ class="{{ $.classes_section | default "bg-primary-color-dark b--dark-gray bb bt ph5 pv4 w-100" }}">
+ <div class="center mw9">
<h3 class="b f3 mv0 light-gray">Hugo Sponsors</h3>
<div class="flex-ns flex-wrap center justify-between pt3">
{{ range .banners }}
- {{ $banner := . }}
- {{if .logo}}
- <div class="{{$classes_box}} o-100"{{ with .bgcolor }} style="background-color: {{ . }};"{{ end}}>
- {{with .link -}}
- {{ $url := printf "%s?%s" . (querify "utm_source" "homepage" "utm_medium" "banner" "utm_campaign" "hugosponsor") | safeURL }}
- {{ if eq (getenv "HUGO_ENV") "production" | or (eq $.cx.Site.Params.env "production") }}
- {{ $gtagID := printf "Sponsor %s %s" $banner.name $gtag | title }}
- <a href="{{ $url }}" onclick="trackOutboundLink({{ printf "'%s', '%s'" $gtagID $url | safeJS }});" class="grow">
- {{ else }}
- <a href="{{ $url }}" class="grow">
- {{ end }}
- {{- end}}
- <img src="{{ .logo }}" alt="Logo for {{ .name }}" class="img h3 center" />
- {{with .link}}</a>{{end}}
- {{with .copy}}
- <p class="center lh-copy gray mv1 tc {{$.classes_copy | default "f5 w-70-ns"}}">
- {{- . -}}
- </p>
- {{end}}
- </div>
- {{else}}
- <div class="{{$classes_box}} o-10">
- <p class="b black tc">Your Logo Here</p>
- </div>
- {{end}}
- {{end}}
+ <div
+ class="{{ $classes_box }} o-100"
+ {{ with .bgcolor }}style="background-color: {{ . }};"{{ end }}>
+ {{ $url := printf "%s?%s" .link (querify "utm_source" $utmSource "utm_medium" "banner" "utm_campaign" (.utm_campaign | default "hugosponsor")) | safeURL }}
+ {{ if eq (getenv "HUGO_ENV") "production" | or (eq $.cx.Site.Params.env "production") }}
+ {{ $gtagID := printf "Sponsor %s %s" .name $gtag | title }}
+ <a
+ href="{{ $url }}"
+ onclick="trackOutboundLink({{ printf "'%s', '%s'" $gtagID $url | safeJS }});"
+ class="grow">
+ <img
+ src="{{ .logo }}"
+ alt="Logo for {{ .name }}"
+ class="img h3 center" />
+ </a>
+ {{ else }}
+ <a href="{{ $url }}" class="grow">
+ <img
+ src="{{ .logo }}"
+ alt="Logo for {{ .name }}"
+ class="img h3 center"
+ /></a>
+ {{ end }}
+ </div>
+ {{ end }}
</div>
</div>
</section>
-{{end}}
+{{ end }}
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/package.json b/_vendor/github.com/gohugoio/gohugoioTheme/package.json
index 9222aad76..012a7b9f9 100644
--- a/_vendor/github.com/gohugoio/gohugoioTheme/package.json
+++ b/_vendor/github.com/gohugoio/gohugoioTheme/package.json
@@ -3,14 +3,7 @@
"version": "1.1.0",
"description": "Default Theme for Hugo Sites",
"main": "index.js",
- "homepage": "https://gohugo.io/",
- "bugs": {
- "url": "https://github.com/gohugoio/gohugoioTheme/issues"
- },
- "repository": {
- "type": "git",
- "url": "git+https://github.com/gohugoio/gohugoioTheme.git"
- },
+ "repository": "",
"author": "budparr",
"license": "MIT",
"scripts": {
@@ -21,14 +14,13 @@
"devDependencies": {
"clean-webpack-plugin": "^1.0.0",
"clipboard": "^2.0.4",
- "css-loader": "^4.3.0",
+ "css-loader": "^1.0.1",
"docsearch.js": "^2.6.1",
"file-loader": "^2.0.0",
"glob-all": "^3.1.0",
- "highlight.js": "^9.13.1",
- "lazysizes": "^5.2.1",
+ "lazysizes": "^4.1.4",
"mini-css-extract-plugin": "^0.4.4",
- "postcss": "^7.0.36",
+ "postcss": "^7.0.5",
"postcss-cssnext": "^3.1.0",
"postcss-import": "^12.0.1",
"postcss-loader": "^3.0.0",
@@ -36,7 +28,7 @@
"scrolldir": "^1.4.0",
"tachyons": "^4.7.0",
"typeface-muli": "0.0.54",
- "webpack": "^4.44.1",
+ "webpack": "^4.25.1",
"webpack-command": "^0.4.2"
},
"dependencies": {}
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/brave-logo.svg b/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/brave-logo.svg
deleted file mode 100644
index 27cdd974d..000000000
--- a/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/brave-logo.svg
+++ /dev/null
@@ -1 +0,0 @@
-<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 461.99 142.7"><defs><style>.cls-1{fill:#fff;}.cls-2{fill:url(#linear-gradient);}.cls-3{fill:#77777a;}</style><linearGradient id="linear-gradient" x1="168.37" y1="199.9" x2="289.96" y2="199.9" gradientUnits="userSpaceOnUse"><stop offset="0" stop-color="#f1562b"/><stop offset="0.3" stop-color="#f1542b"/><stop offset="0.41" stop-color="#f04d2a"/><stop offset="0.49" stop-color="#ef4229"/><stop offset="0.5" stop-color="#ef4029"/><stop offset="0.56" stop-color="#e83e28"/><stop offset="0.67" stop-color="#e13c26"/><stop offset="1" stop-color="#df3c26"/></linearGradient></defs><title>brave_logo_2color_reversed</title><path class="cls-1" d="M320.92,205.1V157h4.6a6.78,6.78,0,0,1,6.78,6.78v21.39c7.37-6.58,13.65-9.21,22-9.38,16-.33,30,11.58,31.28,27.56,1.58,19.1-12.31,33.47-30.4,33.47C335.33,236.82,320.92,224.5,320.92,205.1Zm11.2,3.78c1.12,9.94,10.62,18.15,20.63,18.31,13,.2,21.93-8.3,21.93-20.89S366,185.4,353.31,185.4C339.76,185.4,330.58,195.25,332.12,208.88Z" transform="translate(-168.37 -128.55)"/><path class="cls-1" d="M404.6,177v8.57c7.16-8,11.42-10.09,19.8-10.09a46.18,46.18,0,0,1,7.29.59v11.38a29.47,29.47,0,0,0-7.9-1.06c-6.07,0-11.17,2-14.94,5.75-3.28,3.29-4.25,5.87-4.25,11v31.69H392.82V177Z" transform="translate(-168.37 -128.55)"/><path class="cls-1" d="M434.48,196.12c.61-5.63,1.7-8.68,4.13-11.62,4.86-6,13.61-9,26-9,9.84,0,17,1.53,22,4.81,4.13,2.7,5.83,6.69,5.83,13.73v25.7c0,5.63,1.46,7.63,5.47,7.51a25,25,0,0,0,2.67-.24v7.75a17.53,17.53,0,0,1-6.2.94c-7.41,0-10.81-2.23-13.11-8.68-7.29,6.69-14.82,9.51-25.63,9.51-14.45,0-23.32-6.57-23.32-17.25a15.19,15.19,0,0,1,9.11-14.08c4.37-1.88,7-2.46,19.56-3.76,10.69-1.06,12.51-1.29,15.55-2.23,3.28-1.06,4.74-2.81,4.74-5.75,0-6.22-5.22-9-16.16-9-10.34,0-15.66,2-17.8,7.28a7,7,0,0,1-6.51,4.46ZM481.25,206a115.67,115.67,0,0,1-23,4.23c-10.57,1.06-13.85,3-13.85,8.33,0,5.87,4.86,8.92,14.45,8.92,7.9,0,13.85-2,18.1-5.87,3.4-3.17,4.25-5.4,4.25-10.92Z" transform="translate(-168.37 -128.55)"/><path class="cls-1" d="M529.08,234.84h-3a7,7,0,0,1-6.3-3.91L494.26,177h7.08a10.41,10.41,0,0,1,9.57,6.13l17,38.82L545.46,183a10.41,10.41,0,0,1,9.53-6h6.43l-26.07,54A7,7,0,0,1,529.08,234.84Z" transform="translate(-168.37 -128.55)"/><path class="cls-1" d="M569.41,209.26c1.21,11.15,10,18.07,23,18.07,7.38,0,12.88-2.19,16.35-6.58a10.53,10.53,0,0,1,8.25-4h6.85c-6,13.15-16.64,19.6-32.55,19.6-19.92,0-33.28-12.09-33.28-30.16s13.73-30.75,33.53-30.75c14.33,0,25.87,6.45,30.49,17.25,2.06,4.93,2.92,9.39,2.92,16.54Zm43.48-8.92c-2.67-10.21-10.57-16-21.5-16s-18.83,5.75-21.62,16Z" transform="translate(-168.37 -128.55)"/><path class="cls-2" d="M290,174.71l-4.4-11.95,3.06-6.86a2.35,2.35,0,0,0-.48-2.61l-8.32-8.41a13.43,13.43,0,0,0-14-3.25l-2.33.81-12.71-13.77-21.56-.12h-.14l-21.7.17-12.7,13.88-2.26-.8a13.47,13.47,0,0,0-14.09,3.28l-8.47,8.57a1.87,1.87,0,0,0-.38,2.08l3.19,7.12-4.38,11.94,2.83,10.77,12.91,49.08a25,25,0,0,0,9.67,14s15.67,11.05,31.13,21.09a6.9,6.9,0,0,0,8.61,0c17.37-11.38,31.11-21.13,31.11-21.13a25,25,0,0,0,9.66-14l12.84-49.1Z" transform="translate(-168.37 -128.55)"/><path class="cls-1" d="M232.72,217a18.42,18.42,0,0,0-2.54-.92h-1.53a18.42,18.42,0,0,0-2.54.92l-3.85,1.6c-1.22.51-3.18,1.42-4.35,2l-7.08,3.69a1.35,1.35,0,0,0-.17,2.5l6.15,4.34c1.08.76,2.78,2.1,3.78,3l1.73,1.49c1,.86,2.63,2.29,3.62,3.17l1.64,1.45a2.82,2.82,0,0,0,3.61,0l1.72-1.5,3.62-3.16,1.74-1.52c1-.87,2.69-2.21,3.77-3l6.15-4.4a1.34,1.34,0,0,0-.19-2.49l-7.07-3.59c-1.18-.6-3.14-1.5-4.37-2Z" transform="translate(-168.37 -128.55)"/><path class="cls-1" d="M276.32,177.38l.2-.64a16.84,16.84,0,0,0-.16-2.56,21.57,21.57,0,0,0-2.28-4.3l-4-5.87c-.74-1.1-2-2.84-2.85-3.87l-5.36-6.71a18.74,18.74,0,0,0-1.59-1.86h-.11s-1.08.19-2.38.44l-8.19,1.58-3.59.69a9.33,9.33,0,0,1-3.51-.51l-6.47-2.09c-1.26-.41-3.34-1-4.63-1.28a19.35,19.35,0,0,0-4.09,0c-1.29.3-3.37.88-4.63,1.29l-6.47,2.1a9.33,9.33,0,0,1-3.51.51l-3.59-.68-8.2-1.57c-1.3-.25-2.37-.45-2.38-.44h-.11a18.74,18.74,0,0,0-1.59,1.86l-5.35,6.71c-.82,1-2.11,2.78-2.85,3.87l-4,5.87a31.45,31.45,0,0,0-1.89,3.15,14.32,14.32,0,0,0-.54,3.72l.2.64a9.49,9.49,0,0,0,.37,1.21c.83,1,2.25,2.66,3.16,3.63l14,14.88a4,4,0,0,1,.71,4l-2.29,5.43a7.05,7.05,0,0,0-.11,4.47l.46,1.26a12.15,12.15,0,0,0,3.73,5.23l2.2,1.79a4.16,4.16,0,0,0,4,.48l7.82-3.73a19.88,19.88,0,0,0,4-2.65l6.26-5.65a2.51,2.51,0,0,0,.13-3.6l-14.13-9.52a2.74,2.74,0,0,1-.86-3.47l5.48-10.3a5.35,5.35,0,0,0,.27-4.09,6.25,6.25,0,0,0-3.11-2.82l-17.18-6.49c-1.24-.47-1.17-1,.14-1.08l10.09-1a15.57,15.57,0,0,1,4.71.42l8.78,2.45a2.69,2.69,0,0,1,1.88,3l-3.45,18.84a9.74,9.74,0,0,0-.17,3.18c.14.45,1.32,1,2.61,1.32l5.35,1.14a13,13,0,0,0,4.7,0l4.81-1.09c1.29-.29,2.46-.9,2.61-1.35a9.73,9.73,0,0,0-.18-3.18l-3.47-18.84a2.69,2.69,0,0,1,1.88-3l8.78-2.46a15.56,15.56,0,0,1,4.71-.42l10.09.94c1.32.12,1.38.61.15,1.08l-17.17,6.51a6.25,6.25,0,0,0-3.11,2.82,5.36,5.36,0,0,0,.27,4.09l5.49,10.3a2.74,2.74,0,0,1-.86,3.47l-14.12,9.54a2.51,2.51,0,0,0,.13,3.6l6.27,5.65a19.88,19.88,0,0,0,4,2.64l7.82,3.72a4.16,4.16,0,0,0,4-.49l2.2-1.8a12.14,12.14,0,0,0,3.73-5.24l.46-1.26a7.05,7.05,0,0,0-.11-4.47l-2.3-5.43a4,4,0,0,1,.71-4l14-14.9c.91-1,2.32-2.6,3.15-3.63A9.49,9.49,0,0,0,276.32,177.38Z" transform="translate(-168.37 -128.55)"/><path class="cls-3" d="M630.36,177.72a4.91,4.91,0,1,1-4.89-4.78A4.8,4.8,0,0,1,630.36,177.72Zm-8.59,0a3.7,3.7,0,0,0,3.73,3.82,3.66,3.66,0,0,0,3.64-3.79,3.69,3.69,0,1,0-7.37,0Zm2.94,2.51H623.6v-4.78a9.64,9.64,0,0,1,1.84-.15,3,3,0,0,1,1.66.35,1.33,1.33,0,0,1,.46,1,1.23,1.23,0,0,1-1,1.11v.06a1.41,1.41,0,0,1,.87,1.16,3.61,3.61,0,0,0,.35,1.19h-1.2a4.15,4.15,0,0,1-.38-1.16c-.09-.52-.38-.76-1-.76h-.52Zm0-2.71h.52c.61,0,1.11-.2,1.11-.7s-.32-.73-1-.73a2.6,2.6,0,0,0-.61.06Z" transform="translate(-168.37 -128.55)"/></svg> \ No newline at end of file
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/butter-dark.svg b/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/butter-dark.svg
new file mode 100644
index 000000000..657b75c50
--- /dev/null
+++ b/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/butter-dark.svg
@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 402 58"><g fill="#231F20"><path d="M24.6 23c.4 0 .7-.1 1-.2l10-5.4c1-.5 1.3-1.8.8-2.8-.5-1-1.8-1.3-2.8-.8l-9.9 5.4c-1 .3-1.5 1.3-1.3 2.3.3 1 1.3 1.7 2.3 1.5h-.1zM39.8 30.9c.3 0 .7-.1 1-.3L56.7 22c.6-.3 1-1 1-1.7 0-.8-.3-1.5-.9-1.8-.7-.4-1.4-.4-2.1-.1L38.8 27c-.9.4-1.5 1.4-1.2 2.4.2 1 1.2 1.6 2.2 1.5z"/><path d="M81 19.6c-.4-1.2-1.3-2.2-2.4-2.7L61.4 7.7c-2.8-1.4-6.1-1.4-9 0l-1.4.7L39.1 2C36.3.6 33 .6 30.1 2L2.5 16.9c-1.4.6-2.3 1.9-2.5 3.4v15.2c0 .8.4 1.5 1.1 1.8l35 19c2.8 1.4 6.2 1.4 9 0L80 37.1c.7-.3 1.1-1 1.1-1.8v-15c0-.2-.1-.5-.1-.7zm-76.5.9L32 5.6c1.6-.7 3.5-.7 5.2 0L51 13l3.3-1.8c1.7-.7 3.6-.7 5.2 0l17.1 9.2.2.1-.2.1-33.4 18c-1.7.8-3.6.8-5.2 0l-33.5-18-.2-.1h.2zm38.6 32.2c-1.6.7-3.5.7-5.1 0L4.1 34.3v-9.2L36 42.3c2.8 1.4 6.2 1.4 9 0l32-17.2v9L43.1 52.7zM115.7 10.2h18.2c8.7 0 13.1 3.1 13.1 9.1 0 1.9-.5 3.7-1.6 5.2s-2.6 2.6-4.3 3.2c2.2.4 4.2 1.5 5.7 3.1s2.2 3.6 2.2 5.7c0 3.8-1.4 6.7-4.1 8.7-2.7 2-6.6 3-11.8 3h-17.5v-5.4l1.8-.2c.4 0 .8-.2 1.1-.5.2-.4.3-.9.3-1.3V16.1l-3.1-.3v-5.6zm13.1 6.4v9h2.7c3.5 0 5.3-1.6 5.3-4.8 0-2.8-1.7-4.2-5.1-4.2h-2.9zm0 15.1v9.9h3.7c3.8 0 5.8-1.8 5.8-5.2 0-3.1-1.9-4.7-5.7-4.7h-3.8zM180.7 19v22c0 .5 0 .9.3 1.3.2.3.6.4 1 .5l1.5.1v5.2h-11.7v-3.6h-.2c-1.7 3-4.5 4.4-8.5 4.4-3.1 0-5.3-.8-6.8-2.3-1.4-1.6-2.1-4-2.1-7.3V26.2c0-.4-.1-.8-.4-1.1-.2-.3-.6-.5-1-.5l-1.6-.2V19H164v18.4c-.1 1.1.1 2.2.6 3.1.6.8 1.6 1.1 2.5 1 1.1.1 2.2-.4 2.9-1.2.7-1 1.1-2.2 1-3.4V26.3c0-.5-.1-.9-.3-1.3-.3-.3-.7-.4-1.1-.4l-1.3-.2V19h12.4zM198.9 12.3V19h8.1c2.5-1.1 4.3-3.4 5.5-6.7h5.3V19h6.9l-.5 6.3h-6.4v12.3c-.1 1.1.2 2.2.7 3.2.4.5 1.3.8 2.7.8 1.2 0 2.5-.3 3.6-.8l1.4 6.3c-2.5 1.3-5.2 1.9-7.9 1.8-1.3 0-2.5-.1-3.8-.3-.9-.2-1.8-.4-2.7-.8-.7-.3-1.3-.8-1.8-1.4-.4-.5-.8-1-1.1-1.6-.3-.6-.5-1.3-.6-2-.1-.6-.2-1.3-.3-2V25.3h-9v12.3c-.1 1 .1 2.1.6 3.1.5.7 1.4 1.1 2.3 1 1.1 0 2.2-.3 3.2-.8l1.7 6.2c-2.3 1.2-4.9 1.9-7.5 1.8-3.7 0-6.4-.9-7.9-2.6-1.5-1.7-2.3-4.2-2.3-7.6V25.3h-3.9l.8-5.5c3.6-.8 6.2-3.3 7.6-7.4l5.3-.1zM242.7 18.2c2.7-.1 5.3.6 7.5 2.2 2 1.6 3 4.1 2.8 6.6 0 6.9-5.3 10.2-16 10 .1 1.3.7 2.6 1.7 3.5 1.2 1 2.7 1.4 4.2 1.4 2.6-.1 5.2-.9 7.4-2.3l2.6 6.3c-.5.4-1 .7-1.6.9-1.3.6-2.6 1-4 1.4-1.9.5-3.8.7-5.7.7-4.9 0-8.5-1.3-10.8-4-2.3-2.6-3.5-6.2-3.5-10.7-.1-4.1 1.3-8.2 4-11.4 2.7-3 6.5-4.6 11.4-4.6zm2 9.3c0-.7-.2-1.4-.7-1.9-.5-.5-1.2-.7-1.9-.6-1.4 0-2.8.6-3.6 1.8-1 1.3-1.6 2.9-1.6 4.6 5.2.2 7.7-1.2 7.7-3.9h.1zM272.5 25.5c-1.1 0-2.1.5-2.7 1.3-.7.9-1.1 2.1-1 3.3v12.5l5.1.3v5.3h-18.1V43l1.9-.2c.4.1.8-.1 1.1-.4.2-.4.3-.9.3-1.4V26.2c0-.4-.1-.8-.3-1.2-.3-.3-.6-.4-1-.4l-2-.2V19H268v4.4h.1c.7-1.4 1.7-2.7 3-3.6 1.6-1.1 3.5-1.7 5.4-1.6 1.9-.1 3.7.2 5.4.9v11.3l-7.6.4v-3.9c0-.7-.2-1.1-.5-1.2-.4-.1-.9-.2-1.3-.2zM308.7 17.5c-1.2-.3-2.3-.4-3.4-.4-6.1 0-9.2 3.9-9.2 11.8 0 3.8.8 6.8 2.3 9 1.5 2.2 3.9 3.3 7.1 3.4 1.1 0 2.1-.1 3.2-.4.6-.2 1-.8 1-1.5v-3.7l7.3.4v10.5c-3.8 1.7-7.9 2.5-12.1 2.3-6.1 0-10.8-1.6-14.1-4.9-3.3-3.3-5-8.1-5-14.5 0-3.2.5-6.4 1.6-9.4.9-2.5 2.4-4.6 4.4-6.3 1.8-1.4 3.8-2.5 6-3.3 2.2-.7 4.6-1 6.9-1 4.2-.1 8.3.7 12.2 2.4v10l-7.4.4V19c0-.9-.3-1.4-.8-1.5zM323.6 10.2h14.6l7.5 24.8h.2l7.7-24.7h14.6v5.4l-1.8.2c-.5 0-.9.2-1.2.5-.3.4-.4.9-.3 1.3l1.9 24.8 2.9.1v5.6h-15.3v-5.5l1.8-.2c.4.1.8-.1 1-.4.2-.4.3-.9.2-1.3l-.9-16.1h-.1l-7.2 23.5h-7.1l-7-23.1h-.2l-1 17.3 2.8.2v5.6h-15.3v-5.5l1.8-.2c.5 0 .9-.2 1.2-.5.2-.4.4-.9.4-1.4l2-24.6-3.2-.2v-5.6zM385.5 41.6c3.5 0 5.3-1.4 5.3-4.2 0-1.1-.5-2.2-1.4-2.8-1.4-.8-2.9-1.4-4.5-1.8-1.3-.3-2.7-.8-4-1.3-1.2-.5-2.3-1.2-3.4-1.9-1.2-.9-2.2-2-2.8-3.3-.6-1.5-1-3.2-1-4.8-.1-3.4 1.4-6.7 4-8.8 2.7-2.1 6.2-3.1 10.6-3.1 4-.2 8 .6 11.7 2.2v9.3l-7.4.5v-2.9c0-.8-.3-1.3-.8-1.4-1.1-.3-2.2-.4-3.3-.4-1.1 0-2.2.3-3.1.8-.8.6-1.3 1.6-1.2 2.6-.1 1.1.5 2.2 1.4 2.8 1.5.9 3.1 1.6 4.8 2 1.4.4 2.5.8 3.3 1.1.9.4 1.9.8 2.8 1.3 1 .5 1.9 1.2 2.6 2 .7.9 1.2 1.8 1.6 2.9.5 1.3.7 2.6.7 4 .2 3.6-1.3 7-4.1 9.3-2.7 2.2-6.4 3.3-11.2 3.3-4.3.1-8.6-.7-12.6-2.3v-9.8l7.5-.5v3.2c0 .9.3 1.4.9 1.6 1.1.2 2.3.4 3.6.4z"/></g></svg> \ No newline at end of file
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/butter-light.svg b/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/butter-light.svg
new file mode 100644
index 000000000..a0697df08
--- /dev/null
+++ b/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/butter-light.svg
@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 402 58"><g fill="#fff"><path d="M24.6 23c.4 0 .7-.1 1-.2l10-5.4c1-.5 1.3-1.8.8-2.8-.5-1-1.8-1.3-2.8-.8l-9.9 5.4c-1 .3-1.5 1.3-1.3 2.3.3 1 1.3 1.7 2.3 1.5h-.1zM39.8 30.9c.3 0 .7-.1 1-.3L56.7 22c.6-.3 1-1 1-1.7 0-.8-.3-1.5-.9-1.8-.7-.4-1.4-.4-2.1-.1L38.8 27c-.9.4-1.5 1.4-1.2 2.4.2 1 1.2 1.6 2.2 1.5z"/><path d="M81 19.6c-.4-1.2-1.3-2.2-2.4-2.7L61.4 7.7c-2.8-1.4-6.1-1.4-9 0l-1.4.7L39.1 2C36.3.6 33 .6 30.1 2L2.5 16.9c-1.4.6-2.3 1.9-2.5 3.4v15.2c0 .8.4 1.5 1.1 1.8l35 19c2.8 1.4 6.2 1.4 9 0L80 37.1c.7-.3 1.1-1 1.1-1.8v-15c0-.2-.1-.5-.1-.7zm-76.5.9L32 5.6c1.6-.7 3.5-.7 5.2 0L51 13l3.3-1.8c1.7-.7 3.6-.7 5.2 0l17.1 9.2.2.1-.2.1-33.4 18c-1.7.8-3.6.8-5.2 0l-33.5-18-.2-.1h.2zm38.6 32.2c-1.6.7-3.5.7-5.1 0L4.1 34.3v-9.2L36 42.3c2.8 1.4 6.2 1.4 9 0l32-17.2v9L43.1 52.7zM115.7 10.2h18.2c8.7 0 13.1 3.1 13.1 9.1 0 1.9-.5 3.7-1.6 5.2s-2.6 2.6-4.3 3.2c2.2.4 4.2 1.5 5.7 3.1s2.2 3.6 2.2 5.7c0 3.8-1.4 6.7-4.1 8.7-2.7 2-6.6 3-11.8 3h-17.5v-5.4l1.8-.2c.4 0 .8-.2 1.1-.5.2-.4.3-.9.3-1.3V16.1l-3.1-.3v-5.6zm13.1 6.4v9h2.7c3.5 0 5.3-1.6 5.3-4.8 0-2.8-1.7-4.2-5.1-4.2h-2.9zm0 15.1v9.9h3.7c3.8 0 5.8-1.8 5.8-5.2 0-3.1-1.9-4.7-5.7-4.7h-3.8zM180.7 19v22c0 .5 0 .9.3 1.3.2.3.6.4 1 .5l1.5.1v5.2h-11.7v-3.6h-.2c-1.7 3-4.5 4.4-8.5 4.4-3.1 0-5.3-.8-6.8-2.3-1.4-1.6-2.1-4-2.1-7.3V26.2c0-.4-.1-.8-.4-1.1-.2-.3-.6-.5-1-.5l-1.6-.2V19H164v18.4c-.1 1.1.1 2.2.6 3.1.6.8 1.6 1.1 2.5 1 1.1.1 2.2-.4 2.9-1.2.7-1 1.1-2.2 1-3.4V26.3c0-.5-.1-.9-.3-1.3-.3-.3-.7-.4-1.1-.4l-1.3-.2V19h12.4zM198.9 12.3V19h8.1c2.5-1.1 4.3-3.4 5.5-6.7h5.3V19h6.9l-.5 6.3h-6.4v12.3c-.1 1.1.2 2.2.7 3.2.4.5 1.3.8 2.7.8 1.2 0 2.5-.3 3.6-.8l1.4 6.3c-2.5 1.3-5.2 1.9-7.9 1.8-1.3 0-2.5-.1-3.8-.3-.9-.2-1.8-.4-2.7-.8-.7-.3-1.3-.8-1.8-1.4-.4-.5-.8-1-1.1-1.6-.3-.6-.5-1.3-.6-2-.1-.6-.2-1.3-.3-2V25.3h-9v12.3c-.1 1 .1 2.1.6 3.1.5.7 1.4 1.1 2.3 1 1.1 0 2.2-.3 3.2-.8l1.7 6.2c-2.3 1.2-4.9 1.9-7.5 1.8-3.7 0-6.4-.9-7.9-2.6-1.5-1.7-2.3-4.2-2.3-7.6V25.3h-3.9l.8-5.5c3.6-.8 6.2-3.3 7.6-7.4l5.3-.1zM242.7 18.2c2.7-.1 5.3.6 7.5 2.2 2 1.6 3 4.1 2.8 6.6 0 6.9-5.3 10.2-16 10 .1 1.3.7 2.6 1.7 3.5 1.2 1 2.7 1.4 4.2 1.4 2.6-.1 5.2-.9 7.4-2.3l2.6 6.3c-.5.4-1 .7-1.6.9-1.3.6-2.6 1-4 1.4-1.9.5-3.8.7-5.7.7-4.9 0-8.5-1.3-10.8-4-2.3-2.6-3.5-6.2-3.5-10.7-.1-4.1 1.3-8.2 4-11.4 2.7-3 6.5-4.6 11.4-4.6zm2 9.3c0-.7-.2-1.4-.7-1.9-.5-.5-1.2-.7-1.9-.6-1.4 0-2.8.6-3.6 1.8-1 1.3-1.6 2.9-1.6 4.6 5.2.2 7.7-1.2 7.7-3.9h.1zM272.5 25.5c-1.1 0-2.1.5-2.7 1.3-.7.9-1.1 2.1-1 3.3v12.5l5.1.3v5.3h-18.1V43l1.9-.2c.4.1.8-.1 1.1-.4.2-.4.3-.9.3-1.4V26.2c0-.4-.1-.8-.3-1.2-.3-.3-.6-.4-1-.4l-2-.2V19H268v4.4h.1c.7-1.4 1.7-2.7 3-3.6 1.6-1.1 3.5-1.7 5.4-1.6 1.9-.1 3.7.2 5.4.9v11.3l-7.6.4v-3.9c0-.7-.2-1.1-.5-1.2-.4-.1-.9-.2-1.3-.2zM308.7 17.5c-1.2-.3-2.3-.4-3.4-.4-6.1 0-9.2 3.9-9.2 11.8 0 3.8.8 6.8 2.3 9 1.5 2.2 3.9 3.3 7.1 3.4 1.1 0 2.1-.1 3.2-.4.6-.2 1-.8 1-1.5v-3.7l7.3.4v10.5c-3.8 1.7-7.9 2.5-12.1 2.3-6.1 0-10.8-1.6-14.1-4.9-3.3-3.3-5-8.1-5-14.5 0-3.2.5-6.4 1.6-9.4.9-2.5 2.4-4.6 4.4-6.3 1.8-1.4 3.8-2.5 6-3.3 2.2-.7 4.6-1 6.9-1 4.2-.1 8.3.7 12.2 2.4v10l-7.4.4V19c0-.9-.3-1.4-.8-1.5zM323.6 10.2h14.6l7.5 24.8h.2l7.7-24.7h14.6v5.4l-1.8.2c-.5 0-.9.2-1.2.5-.3.4-.4.9-.3 1.3l1.9 24.8 2.9.1v5.6h-15.3v-5.5l1.8-.2c.4.1.8-.1 1-.4.2-.4.3-.9.2-1.3l-.9-16.1h-.1l-7.2 23.5h-7.1l-7-23.1h-.2l-1 17.3 2.8.2v5.6h-15.3v-5.5l1.8-.2c.5 0 .9-.2 1.2-.5.2-.4.4-.9.4-1.4l2-24.6-3.2-.2v-5.6zM385.5 41.6c3.5 0 5.3-1.4 5.3-4.2 0-1.1-.5-2.2-1.4-2.8-1.4-.8-2.9-1.4-4.5-1.8-1.3-.3-2.7-.8-4-1.3-1.2-.5-2.3-1.2-3.4-1.9-1.2-.9-2.2-2-2.8-3.3-.6-1.5-1-3.2-1-4.8-.1-3.4 1.4-6.7 4-8.8 2.7-2.1 6.2-3.1 10.6-3.1 4-.2 8 .6 11.7 2.2v9.3l-7.4.5v-2.9c0-.8-.3-1.3-.8-1.4-1.1-.3-2.2-.4-3.3-.4-1.1 0-2.2.3-3.1.8-.8.6-1.3 1.6-1.2 2.6-.1 1.1.5 2.2 1.4 2.8 1.5.9 3.1 1.6 4.8 2 1.4.4 2.5.8 3.3 1.1.9.4 1.9.8 2.8 1.3 1 .5 1.9 1.2 2.6 2 .7.9 1.2 1.8 1.6 2.9.5 1.3.7 2.6.7 4 .2 3.6-1.3 7-4.1 9.3-2.7 2.2-6.4 3.3-11.2 3.3-4.3.1-8.6-.7-12.6-2.3v-9.8l7.5-.5v3.2c0 .9.3 1.4.9 1.6 1.1.2 2.3.4 3.6.4z"/></g></svg> \ No newline at end of file
diff --git a/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/forestry-logotype.svg b/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/forestry-logotype.svg
deleted file mode 100644
index ac95cd444..000000000
--- a/_vendor/github.com/gohugoio/gohugoioTheme/static/images/sponsors/forestry-logotype.svg
+++ /dev/null
@@ -1 +0,0 @@
-<svg id="Layer_1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 395.8 102"><style>.st0{fill:#181919}</style><path class="st0" d="M98.7 34.3L80 53V41.7l24.3-24.3-5.6-5.7L80 30.4V.6h-8v29.8L53.3 11.7l-5.6 5.7L72 41.7V53L53.3 34.4 31.9 12.9V.6h-8v12.3L-.4 37.2l5.6 5.7 18.7-18.7v11.4L-.4 59.8l5.6 5.7 18.7-18.6v55.5h8V46.8l18.6 18.7 5.7-5.7-24.3-24.3V24.2l18.6 18.7L72 64.3v38.1h8V64.3L104.3 40zM126.8 53.1h6.9V37.2h16.8V31h-16.8V20.9h17.9v-6.1h-24.8zM190.2 19.1c-1.8-1.8-3.9-3.1-6.4-4-2.5-.9-5.2-1.4-8.2-1.3-3 0-5.7.5-8.1 1.4-2.5 1-4.6 2.3-6.4 4.1-1.8 1.8-3.2 3.9-4.2 6.4-1 2.5-1.5 5.3-1.5 8.4 0 3 .5 5.7 1.5 8.2 1 2.5 2.4 4.6 4.2 6.3 1.8 1.7 3.9 3.1 6.4 4.1 2.5 1 5.2 1.4 8.1 1.4 3 0 5.7-.6 8.2-1.5 2.5-1 4.6-2.4 6.4-4.1 1.8-1.8 3.2-3.9 4.2-6.3 1-2.5 1.5-5.2 1.5-8.2 0-3.1-.5-5.8-1.5-8.3-1-2.7-2.4-4.8-4.2-6.6zm-2.3 20.2c-.6 1.7-1.5 3.2-2.7 4.5-1.2 1.3-2.5 2.3-4.2 3-1.6.7-3.4 1.1-5.4 1.1-2 0-3.8-.4-5.4-1.1-1.6-.7-3-1.7-4.1-3-1.2-1.3-2-2.8-2.7-4.5-.6-1.7-.9-3.6-.9-5.7 0-1.9.3-3.7.9-5.4.6-1.7 1.5-3.1 2.7-4.4 1.2-1.2 2.5-2.2 4.1-2.9 1.6-.7 3.4-1.1 5.4-1.1 2 0 3.8.3 5.4 1.1 1.6.7 3 1.7 4.2 2.9 1.2 1.2 2 2.7 2.7 4.4.6 1.7 1 3.4 1 5.4-.1 2.1-.4 4-1 5.7zM226.5 32.7c1.5-1.9 2.3-4.2 2.3-7 0-2.2-.4-3.9-1.2-5.4-.8-1.4-1.9-2.5-3.2-3.4-1.3-.8-2.9-1.4-4.6-1.8-1.7-.3-3.5-.5-5.3-.5h-13.3v38.3h6.8V36.8h5l8.9 16.2h8.2l-10.2-16.9c2.9-.4 5.1-1.5 6.6-3.4zm-10.3-1.8c-1 .1-1.9.1-2.9.1H208V20.6h5.9c.9 0 1.8.1 2.7.2.9.1 1.8.3 2.5.7.8.3 1.4.9 1.8 1.5.5.7.7 1.6.7 2.7 0 1.3-.3 2.2-.8 2.9-.5.7-1.2 1.2-2 1.6-.7.4-1.6.6-2.6.7zM241.6 36.5h17.6v-6.2h-17.6v-9.4h18.6v-6.1h-25.4v38.3h26.4v-6.2h-19.6zM286.8 33c-1.3-.8-2.8-1.5-4.4-1.9-1.6-.5-3-1-4.4-1.5-1.3-.5-2.5-1.1-3.4-1.8-.9-.7-1.4-1.7-1.4-3 0-.9.2-1.6.5-2.2.4-.6.8-1.1 1.4-1.5.6-.4 1.3-.7 2-.9.7-.2 1.5-.3 2.3-.3 1.3 0 2.6.2 3.8.7 1.2.5 2.2 1.3 2.9 2.3l5-5.2c-1.5-1.4-3.2-2.4-5.1-3-1.9-.6-3.8-.9-5.9-.9-1.8 0-3.5.2-5.2.7-1.7.5-3.2 1.2-4.5 2.1-1.3 1-2.4 2.2-3.2 3.6-.8 1.4-1.2 3.2-1.2 5.1 0 2.3.5 4.1 1.4 5.4.9 1.4 2 2.4 3.3 3.2 1.3.8 2.8 1.5 4.4 1.9 1.6.5 3 1 4.4 1.5 1.3.5 2.5 1.2 3.4 1.9.9.8 1.4 1.8 1.4 3.2 0 .9-.2 1.6-.6 2.3-.4.7-.9 1.2-1.6 1.7-.7.4-1.4.8-2.2 1-.8.2-1.6.3-2.4.3-1.5 0-2.9-.3-4.3-1.1s-2.4-1.7-3.3-2.9l-5.1 5c1.6 1.9 3.5 3.2 5.7 4 2.2.8 4.5 1.2 6.9 1.2 1.9 0 3.7-.3 5.4-.8 1.7-.5 3.2-1.3 4.5-2.3 1.3-1 2.3-2.3 3.1-3.8.8-1.5 1.1-3.3 1.1-5.4 0-2.3-.5-4.1-1.3-5.5-.9-1.1-2-2.2-3.4-3.1zM294.4 20.9h11.7v32.2h6.8V20.9h11.8v-6.1h-30.3zM356 32.7c1.5-1.9 2.3-4.2 2.3-7 0-2.2-.4-3.9-1.2-5.4-.8-1.4-1.9-2.5-3.2-3.4-1.3-.8-2.9-1.4-4.6-1.8-1.7-.3-3.5-.5-5.3-.5h-13.3v38.3h6.8V36.8h5l8.9 16.2h8.2l-10.2-16.9c2.9-.4 5-1.5 6.6-3.4zm-10.3-1.8c-1 .1-1.9.1-2.9.1h-5.3V20.6h5.9c.9 0 1.8.1 2.7.2.9.1 1.8.3 2.5.7.8.3 1.4.9 1.8 1.5.5.7.7 1.6.7 2.7 0 1.3-.3 2.2-.8 2.9-.5.7-1.2 1.2-2 1.6-.7.4-1.6.6-2.6.7zM387.1 14.8L377.6 30l-9.4-15.2h-8.6L374 36.7v16.4h6.8V36.7l14.4-21.9z"/><g><path class="st0" d="M136 67.6h2.4l9 21.1h-2.9l-2.1-5.2h-10.5l-2.2 5.2h-2.8l9.1-21.1zm1.1 3.2l-4.4 10.4h8.6l-4.2-10.4zM173.1 72c-.6-.9-1.4-1.5-2.4-1.9s-1.9-.6-2.9-.6c-1.2 0-2.2.2-3.2.7s-1.8 1.1-2.5 1.9c-.7.8-1.3 1.7-1.7 2.8s-.6 2.2-.6 3.3c0 1.2.2 2.4.6 3.4.4 1.1.9 2 1.7 2.8.7.8 1.5 1.4 2.5 1.9s2.1.7 3.3.7c1.3 0 2.4-.3 3.5-.8 1-.5 1.9-1.2 2.6-2.2l1.9 1.6c-1 1.3-2.1 2.2-3.4 2.8-1.3.6-2.9.9-4.5.9-1.5 0-2.9-.3-4.2-.8-1.3-.6-2.4-1.3-3.4-2.3-1-1-1.7-2.1-2.3-3.5-.5-1.3-.8-2.8-.8-4.4 0-1.5.3-3 .8-4.3s1.3-2.5 2.2-3.5 2.1-1.8 3.4-2.4c1.3-.6 2.7-.9 4.3-.9 1.4 0 2.8.3 4.1.8 1.3.5 2.4 1.4 3.3 2.5l-2.3 1.5zM179.3 67.6h3.7l7.1 16.5h.1l7.2-16.5h3.6v21.1h-2.5V71h-.1l-7.6 17.7h-1.5L181.9 71h-.1v17.7h-2.5V67.6zM216.3 71.3c-.4-.7-1-1.2-1.7-1.5-.7-.3-1.4-.5-2.2-.5-.6 0-1.1.1-1.6.2s-1 .3-1.4.6c-.4.3-.8.6-1 1.1-.3.5-.4 1-.4 1.6 0 .5.1.9.2 1.3s.4.7.7 1c.3.3.8.6 1.4.8.6.3 1.3.5 2.1.8.8.3 1.6.5 2.4.8.8.3 1.4.7 2 1.1.6.5 1.1 1 1.4 1.7.3.7.5 1.5.5 2.6s-.2 2-.6 2.7c-.4.8-1 1.4-1.7 1.9s-1.5.9-2.4 1.1-1.8.4-2.8.4c-.6 0-1.2-.1-1.8-.2-.6-.1-1.2-.3-1.8-.5-.6-.2-1.1-.5-1.6-.9s-.9-.8-1.3-1.4l2.1-1.8c.5.8 1.1 1.4 1.9 1.8.8.4 1.7.6 2.6.6.5 0 1.1-.1 1.6-.2s1-.4 1.5-.7c.4-.3.8-.7 1.1-1.1.3-.5.4-1 .4-1.6 0-.7-.1-1.2-.3-1.6-.2-.4-.6-.8-1-1.1-.5-.3-1-.6-1.7-.8-.7-.2-1.5-.5-2.4-.8-.8-.2-1.4-.5-2.1-.8-.6-.3-1.2-.7-1.7-1.1-.5-.4-.8-1-1.1-1.6-.3-.6-.4-1.4-.4-2.2 0-1 .2-1.9.6-2.6.4-.8.9-1.4 1.6-1.9.7-.5 1.4-.9 2.3-1.1.9-.3 1.7-.4 2.7-.4 1.2 0 2.3.2 3.3.5 1 .4 1.9 1 2.6 1.9l-2 1.9zM231.1 67.6h13.1v2.3h-10.6v7h9.8v2.3h-9.8v9.5h-2.5V67.6zM257.5 89.2c-1.6 0-3.1-.3-4.4-.8-1.3-.6-2.5-1.3-3.5-2.3-1-1-1.7-2.2-2.3-3.5s-.8-2.8-.8-4.4c0-1.6.3-3.1.8-4.4.5-1.4 1.3-2.5 2.3-3.5 1-1 2.1-1.8 3.5-2.3 1.3-.6 2.8-.8 4.4-.8 1.6 0 3.1.3 4.4.8 1.3.6 2.5 1.3 3.5 2.3 1 1 1.7 2.2 2.3 3.5.5 1.4.8 2.8.8 4.4 0 1.6-.3 3.1-.8 4.4s-1.3 2.5-2.3 3.5c-1 1-2.1 1.8-3.5 2.3-1.4.6-2.8.8-4.4.8zm0-2.3c1.2 0 2.4-.2 3.4-.7 1-.5 1.9-1.1 2.6-1.9.7-.8 1.3-1.7 1.7-2.8.4-1.1.6-2.2.6-3.4 0-1.2-.2-2.3-.6-3.4-.4-1.1-1-2-1.7-2.8-.7-.8-1.6-1.4-2.6-1.9s-2.1-.7-3.4-.7c-1.2 0-2.4.2-3.4.7-1 .5-1.9 1.1-2.6 1.9-.7.8-1.3 1.7-1.7 2.8-.4 1.1-.6 2.2-.6 3.4 0 1.2.2 2.3.6 3.4.4 1.1 1 2 1.7 2.8.7.8 1.6 1.4 2.6 1.9s2.1.7 3.4.7zM272.5 67.6h5.4c1 0 2 .1 3 .2s1.9.4 2.7.8c.8.4 1.4 1 1.9 1.7.5.8.7 1.8.7 3.1 0 1.5-.5 2.8-1.4 3.7s-2.2 1.6-3.9 1.8l6 9.7h-3.1l-5.7-9.5H275v9.5h-2.5v-21zm2.5 9.3h2.2c.7 0 1.4 0 2.2-.1.7 0 1.4-.2 2.1-.4s1.1-.6 1.5-1c.4-.5.6-1.1.6-2 0-.8-.1-1.4-.4-1.8-.3-.5-.7-.8-1.2-1.1s-1-.4-1.6-.5c-.6-.1-1.2-.1-1.8-.1H275v7zM298.9 67.6h2.5v8.9h11.2v-8.9h2.5v21.1h-2.5v-9.8h-11.2v9.8h-2.5V67.6zM336.2 80.7c0 1.2-.1 2.2-.4 3.3-.3 1-.7 1.9-1.4 2.7-.6.8-1.4 1.4-2.5 1.9-1 .5-2.2.7-3.7.7s-2.7-.2-3.7-.7c-1-.5-1.8-1.1-2.5-1.9-.6-.8-1.1-1.7-1.4-2.7-.3-1-.4-2.1-.4-3.3v-13h2.5v12.7c0 .9.1 1.7.3 2.5s.5 1.5.9 2.1c.4.6 1 1.1 1.7 1.5.7.4 1.6.6 2.6.6s1.9-.2 2.6-.6 1.2-.9 1.7-1.5c.4-.6.7-1.3.9-2.1.2-.8.3-1.6.3-2.5V67.6h2.5v13.1zM359.3 87.3c-1.2.7-2.5 1.2-3.8 1.5-1.3.3-2.7.5-4.1.5-1.6 0-3.2-.3-4.5-.8-1.4-.5-2.6-1.3-3.6-2.3-1-1-1.8-2.1-2.3-3.5-.6-1.4-.8-2.9-.8-4.5 0-1.7.3-3.2.9-4.5s1.4-2.5 2.4-3.5 2.2-1.7 3.6-2.2c1.4-.5 2.8-.8 4.4-.8 1.4 0 2.7.2 4 .6s2.4 1.1 3.4 2.1l-1.9 2c-.7-.8-1.6-1.4-2.6-1.8-1-.4-2.1-.6-3.1-.6-1.2 0-2.3.2-3.4.7-1 .4-1.9 1-2.7 1.8-.8.8-1.4 1.7-1.8 2.8s-.6 2.2-.6 3.5c0 1.2.2 2.4.6 3.5s1 2 1.8 2.8c.8.8 1.7 1.4 2.8 1.8s2.3.7 3.5.7c.9 0 1.7-.1 2.7-.3.9-.2 1.8-.5 2.6-.9v-6.5h-4.9v-2.3h7.4v10.2zM374.3 89.2c-1.6 0-3.1-.3-4.4-.8-1.3-.6-2.5-1.3-3.5-2.3-1-1-1.7-2.2-2.3-3.5s-.8-2.8-.8-4.4c0-1.6.3-3.1.8-4.4.5-1.4 1.3-2.5 2.3-3.5 1-1 2.1-1.8 3.5-2.3 1.3-.6 2.8-.8 4.4-.8 1.6 0 3.1.3 4.4.8 1.3.6 2.5 1.3 3.5 2.3 1 1 1.7 2.2 2.3 3.5.5 1.4.8 2.8.8 4.4 0 1.6-.3 3.1-.8 4.4s-1.3 2.5-2.3 3.5c-1 1-2.1 1.8-3.5 2.3-1.3.6-2.8.8-4.4.8zm0-2.3c1.2 0 2.4-.2 3.4-.7 1-.5 1.9-1.1 2.6-1.9.7-.8 1.3-1.7 1.7-2.8.4-1.1.6-2.2.6-3.4 0-1.2-.2-2.3-.6-3.4-.4-1.1-1-2-1.7-2.8-.7-.8-1.6-1.4-2.6-1.9s-2.1-.7-3.4-.7c-1.2 0-2.4.2-3.4.7-1 .5-1.9 1.1-2.6 1.9-.7.8-1.3 1.7-1.7 2.8-.4 1.1-.6 2.2-.6 3.4 0 1.2.2 2.3.6 3.4.4 1.1 1 2 1.7 2.8.7.8 1.6 1.4 2.6 1.9 1.1.5 2.2.7 3.4.7z"/></g></svg> \ No newline at end of file
diff --git a/_vendor/modules.txt b/_vendor/modules.txt
index 2147e7a1c..1ba50a741 100644
--- a/_vendor/modules.txt
+++ b/_vendor/modules.txt
@@ -1 +1 @@
-# github.com/gohugoio/gohugoioTheme v0.0.0-20220912070954-88dcaf003b4d
+# github.com/gohugoio/gohugoioTheme v0.0.0-20221116211530-5ae8dcdd68d6
diff --git a/config.toml b/config.toml
deleted file mode 100644
index ef8d99d6d..000000000
--- a/config.toml
+++ /dev/null
@@ -1,80 +0,0 @@
-baseURL = "https://gohugo.io/"
-paginate = 100
-defaultContentLanguage = "en"
-enableEmoji = true
-timeZone = "Europe/Oslo"
-# Set the unicode character used for the "return" link in page footnotes.
-footnotereturnlinkcontents = "↩"
-languageCode = "en-us"
-title = "Hugo"
-
- ignoreErrors = ["error-remote-getjson", "error-missing-instagram-accesstoken"]
-
-
-googleAnalytics = "UA-7131036-4"
-
-pluralizeListTitles = false
-
-# We do redirects via Netlify's _redirects file, generated by Hugo (see "outputs" below).
-disableAliases = true
-
-[minify]
- [minify.tdewolff]
- [minify.tdewolff.css]
- [minify.tdewolff.html]
- keepWhitespace = true
-
-[module]
- [module.hugoVersion]
- min = "0.56.0"
- [[module.imports]]
- path = "github.com/gohugoio/gohugoioTheme"
-
-[outputs]
-home = [ "HTML", "RSS", "REDIR", "HEADERS" ]
-section = [ "HTML", "RSS"]
-
-[mediaTypes]
-[mediaTypes."text/netlify"]
-delimiter = ""
-
-[outputFormats]
-[outputFormats.REDIR]
-mediatype = "text/netlify"
-baseName = "_redirects"
-isPlainText = true
-notAlternative = true
-[outputFormats.HEADERS]
-mediatype = "text/netlify"
-baseName = "_headers"
-isPlainText = true
-notAlternative = true
-
-[related]
-
-threshold = 80
-includeNewer = true
-toLower = false
-
-[[related.indices]]
-name = "keywords"
-weight = 100
-[[related.indices]]
-name = "date"
-weight = 10
-pattern = "2006"
-
-[social]
-twitter = "GoHugoIO"
-
-
-[imaging]
-# See https://github.com/disintegration/imaging
-# CatmullRom is a sharp bicubic filter which should fit the docs site well with its many screenshots.
-# Note that you can also set this per image processing.
-resampleFilter = "CatmullRom"
-
-# Default JPEG quality setting. Default is 75.
-quality = 75
-
-anchor = "smart"
diff --git a/config/_default/config.toml b/config/_default/config.toml
index 4d3bb1f60..f4965dff1 100644
--- a/config/_default/config.toml
+++ b/config/_default/config.toml
@@ -1,19 +1,28 @@
baseURL = "https://gohugo.io/"
-paginate = 100
defaultContentLanguage = "en"
enableEmoji = true
-# Set the unicode character used for the "return" link in page footnotes.
-footnotereturnlinkcontents = "↩"
-languageCode = "en-us"
-title = "Hugo"
-
googleAnalytics = "UA-7131036-4"
-
+ignoreErrors = ["error-remote-getjson", "error-missing-instagram-accesstoken"]
+languageCode = "en-us"
+paginate = 100
pluralizeListTitles = false
+timeZone = "Europe/Oslo"
+title = "Hugo"
# We do redirects via Netlify's _redirects file, generated by Hugo (see "outputs" below).
disableAliases = true
+[minify]
+[minify.tdewolff]
+[minify.tdewolff.html]
+keepWhitespace = true
+
+[module]
+[module.hugoVersion]
+min = "0.56.0"
+[[module.imports]]
+path = "github.com/gohugoio/gohugoioTheme"
+
[outputs]
home = [ "HTML", "RSS", "REDIR", "HEADERS" ]
section = [ "HTML", "RSS"]
@@ -48,13 +57,10 @@ maxAge = "1440h"
dir = ":resourceDir/_gen"
maxAge = -1
-
[related]
-
threshold = 80
includeNewer = true
toLower = false
-
[[related.indices]]
name = "keywords"
weight = 100
@@ -66,25 +72,13 @@ pattern = "2006"
[social]
twitter = "GoHugoIO"
-
-# MARKDOWN
-## Configuration for BlackFriday markdown parser: https://github.com/russross/blackfriday
-[blackfriday]
-plainIDAnchors = true
-# See https://github.com/gohugoio/hugo/issues/2424
-hrefTargetBlank = false
-angledQuotes = false
-latexDashes = true
-
[imaging]
# See https://github.com/disintegration/imaging
# CatmullRom is a sharp bicubic filter which should fit the docs site well with its many screenshots.
# Note that you can also set this per image processing.
resampleFilter = "CatmullRom"
-
# Default JPEG quality setting. Default is 75.
quality = 75
-
anchor = "smart"
[taxonomies]
diff --git a/config/_default/menus/menus.en.toml b/config/_default/menus/menus.en.toml
index a31218a4f..7a956a47f 100644
--- a/config/_default/menus/menus.en.toml
+++ b/config/_default/menus/menus.en.toml
@@ -1,114 +1,102 @@
[[docs]]
name = "About Hugo"
- weight = 1
+ weight = 10
identifier = "about"
url = "/about/"
[[docs]]
+ name = "Installation"
+ weight = 20
+ identifier = "installation"
+ url = "/installation/"
+
+[[docs]]
name = "Getting Started"
- weight = 5
+ weight = 30
identifier = "getting-started"
url = "/getting-started/"
[[docs]]
name = "Hugo Modules"
- weight = 15
+ weight = 40
identifier = "modules"
post = "break"
url = "/hugo-modules/"
-# Core Menus
+# Core menus
[[docs]]
name = "Content Management"
- weight = 20
+ weight = 50
identifier = "content-management"
post = "expanded"
url = "/content-management/"
[[docs]]
name = "Templates"
- weight = 25
+ weight = 60
identifier = "templates"
-
url = "/templates/"
[[docs]]
name = "Functions"
- weight = 30
+ weight = 70
identifier = "functions"
url = "/functions/"
[[docs]]
name = "Variables"
- weight = 35
+ weight = 80
identifier = "variables"
url = "/variables/"
+
[[docs]]
name = "Hugo Pipes"
- weight = 36
+ weight = 90
identifier = "pipes"
url = "/hugo-pipes/"
+
[[docs]]
name = "CLI"
- weight = 40
+ weight = 100
post = "break"
identifier = "commands"
url = "/commands/"
-
-
-# LOW LEVEL ITEMS
-
+# Low level items
[[docs]]
name = "Troubleshooting"
- weight = 60
+ weight = 110
identifier = "troubleshooting"
url = "/troubleshooting/"
[[docs]]
name = "Tools"
- weight = 70
+ weight = 120
identifier = "tools"
url = "/tools/"
[[docs]]
name = "Hosting & Deployment"
- weight = 80
+ weight = 130
identifier = "hosting-and-deployment"
url = "/hosting-and-deployment/"
[[docs]]
name = "Contribute"
- weight = 100
+ weight = 140
post = "break"
identifier = "contribute"
url = "/contribute/"
-#[[docs]]
-# name = "Tags"
-# weight = 120
-# identifier = "tags"
-# url = "/tags/"
-
-
-# [[docs]]
-# name = "Categories"
-# weight = 140
-# identifier = "categories"
-# url = "/categories/"
-
######## QUICKLINKS
- [[quicklinks]]
- name = "Fundamentals"
- weight = 1
- identifier = "fundamentals"
- url = "/tags/fundamentals/"
-
-
-
+[[quicklinks]]
+ name = "Fundamentals"
+ weight = 1
+ identifier = "fundamentals"
+ url = "/tags/fundamentals/"
######## GLOBAL ITEMS TO BE SHARED WITH THE HUGO SITES
@@ -118,37 +106,37 @@
identifier = "news"
url = "/news/"
- [[global]]
- name = "Docs"
- weight = 5
- identifier = "docs"
- url = "/documentation/"
-
- [[global]]
- name = "Themes"
- weight = 10
- identifier = "themes"
- url = "https://themes.gohugo.io/"
-
- [[global]]
- name = "Showcase"
- weight = 20
- identifier = "showcase"
- url = "/showcase/"
-
- # Anything with a weight > 100 gets an external icon
- [[global]]
- name = "Community"
- weight = 150
- icon = true
- identifier = "community"
- post = "external"
- url = "https://discourse.gohugo.io/"
-
-
- [[global]]
- name = "GitHub"
- weight = 200
- identifier = "github"
- post = "external"
- url = "https://github.com/gohugoio/hugo" \ No newline at end of file
+[[global]]
+ name = "Docs"
+ weight = 5
+ identifier = "docs"
+ url = "/documentation/"
+
+[[global]]
+ name = "Themes"
+ weight = 10
+ identifier = "themes"
+ url = "https://themes.gohugo.io/"
+
+[[global]]
+ name = "Showcase"
+ weight = 20
+ identifier = "showcase"
+ url = "/showcase/"
+
+# Anything with a weight > 100 gets an external icon
+
+[[global]]
+ name = "Community"
+ weight = 150
+ icon = true
+ identifier = "community"
+ post = "external"
+ url = "https://discourse.gohugo.io/"
+
+[[global]]
+ name = "GitHub"
+ weight = 200
+ identifier = "github"
+ post = "external"
+ url = "https://github.com/gohugoio/hugo"
diff --git a/config/production/config.toml b/config/production/config.toml
index 961f04d35..a54fe5669 100644
--- a/config/production/config.toml
+++ b/config/production/config.toml
@@ -1,6 +1,6 @@
# Config for production
-# This is turned off in development as it is relatively slow.
+# This is turned off in development as it is relatively slow.
# This is needed to get accurate lastMod and Git commit info
# on the docs pages.
enableGitInfo = true \ No newline at end of file
diff --git a/content/en/about/benefits.md b/content/en/about/benefits.md
index d5c13a9c3..e4fec5bb2 100644
--- a/content/en/about/benefits.md
+++ b/content/en/about/benefits.md
@@ -34,7 +34,6 @@ This has many benefits. The most noticeable is performance. HTTP servers are *ve
* ["Top 10 Static Website Generators", Netlify blog][]
* ["The Resurgence of Static", dotCMS][dotcms]
-
["An Introduction to Static Site Generators", David Walsh]: https://davidwalsh.name/introduction-static-site-generators
["Static Site Generators", O'Reilly]: https://github.com/gohugoio/hugoDocs/files/1242701/static-site-generators.pdf
["Top 10 Static Website Generators", Netlify blog]: https://www.netlify.com/blog/2016/05/02/top-ten-static-website-generators/
diff --git a/content/en/about/features.md b/content/en/about/features.md
index ed8c25821..5e94de38c 100644
--- a/content/en/about/features.md
+++ b/content/en/about/features.md
@@ -54,7 +54,6 @@ toc: true
* Support for [Go][] HTML templates
* [Syntax highlighting][] powered by [Chroma][]
-
[aliases]: /content-management/urls/#aliases
[Chroma]: https://github.com/alecthomas/chroma
[content summaries]: /content-management/summaries/
@@ -64,11 +63,11 @@ toc: true
[Extremely fast]: https://github.com/bep/hugo-benchmark
[front matter]: /content-management/front-matter/
[functions]: /functions/
-[Go]: https://golang.org/pkg/html/template/
+[Go]: https://pkg.go.dev/html/template
[Google Analytics]: https://google-analytics.com/
[homepage]: /templates/homepage/
[hostanywhere]: /hosting-and-deployment/
-[install]: /getting-started/installing/
+[install]: /installation/
[LiveReload]: /getting-started/usage/
[organization for your projects]: /getting-started/directory-structure/
[pagevars]: /variables/page/
diff --git a/content/en/about/hugo-and-gdpr.md b/content/en/about/hugo-and-gdpr.md
index 269c5d432..2d4fba872 100644
--- a/content/en/about/hugo-and-gdpr.md
+++ b/content/en/about/hugo-and-gdpr.md
@@ -16,7 +16,6 @@ aliases: [/privacy/,/gdpr/]
toc: true
---
-
General Data Protection Regulation ([GDPR](https://en.wikipedia.org/wiki/General_Data_Protection_Regulation)) is a regulation in EU law on data protection and privacy for all individuals within the European Union and the European Economic Area. It became enforceable on 25 May 2018.
**Hugo is a static site generator. By using Hugo you are already standing on very solid ground. Static HTML files on disk are much easier to reason about compared to server and database driven web sites.**
@@ -95,6 +94,7 @@ useSessionStorage
{{% warning %}}
`useSessionStorage` is not supported when using Google Analytics v4 (gtag.js).
{{% /warning %}}
+
### Instagram
simple
@@ -116,8 +116,7 @@ enableDNT
simple
: If simple mode is enabled, a static and no-JS version of a tweet will be built.
-
-**Note:** If you use the _simple mode_ for Twitter, you may want to disable the inlines styles provided by Hugo:
+**Note:** If you use the _simple mode_ for Twitter, you may want to disable the inline styles provided by Hugo:
{{< code-toggle file="config">}}
[services]
@@ -137,4 +136,3 @@ enableDNT
simple
: If simple mode is enabled, the video thumbnail is fetched from Vimeo's servers and it is overlayed with a play button. If the user clicks to play the video, it will open in a new tab directly on Vimeo's website.
-
diff --git a/content/en/about/security-model/index.md b/content/en/about/security-model/index.md
index 461c7fe77..66cb15463 100644
--- a/content/en/about/security-model/index.md
+++ b/content/en/about/security-model/index.md
@@ -10,7 +10,6 @@ menu:
weight: 4
weight: 5
sections_weight: 5
-draft: false
aliases: [/security/]
toc: true
---
@@ -28,11 +27,8 @@ But when developing and building your site, the runtime is the `hugo` executable
* User-defined components have read-only access to the filesystem.
* We shell out to some external binaries to support [Asciidoctor](/content-management/formats/#list-of-content-formats) and similar, but those binaries and their flags are predefined and disabled by default (see [Security Policy](#security-policy)). General functions to run arbitrary external OS commands have been [discussed](https://github.com/gohugoio/hugo/issues/796), but not implemented because of security concerns.
-
## Security Policy
-{{< new-in "0.91.0" >}}
-
Hugo has a built-in security policy that restricts access to [os/exec](https://pkg.go.dev/os/exec), remote communication and similar.
The default configuration is listed below. Any build using features not in the allow list of the security policy will fail with a detailed message about what needs to be done. Most of these settings are allow lists (string or slice, [Regular Expressions](https://pkg.go.dev/regexp) or `none` which matches nothing).
@@ -41,7 +37,7 @@ The default configuration is listed below. Any build using features not in the a
Note that these and other config settings in Hugo can be overridden by the OS environment. If you want to block all remote HTTP fetching of data:
-```
+```txt
HUGO_SECURITY_HTTP_URLS=none hugo
```
@@ -57,7 +53,7 @@ These are the security threats as defined by [OWASP](https://en.wikipedia.org/wi
For HTML output, this is the core security model:
-https://golang.org/pkg/html/template/#hdr-Security_Model
+<https://pkg.go.dev/html/template#hdr-Security_Model>
In short:
diff --git a/content/en/about/what-is-hugo.md b/content/en/about/what-is-hugo.md
index 69ca1fddb..01fac90c8 100644
--- a/content/en/about/what-is-hugo.md
+++ b/content/en/about/what-is-hugo.md
@@ -47,7 +47,7 @@ Hugo is for people building a blog, a company site, a portfolio site, documentat
[Firebase]: https://firebase.google.com/docs/hosting/ "Firebase static hosting"
[GitHub Pages]: https://pages.github.com/
[GitLab Pages]: https://about.gitlab.com/features/pages/
-[Go language]: https://golang.org/
+[Go language]: https://go.dev/
[GoDaddy]: https://www.godaddy.com/ "GoDaddy.com Hosting"
[Google Cloud Storage]: https://cloud.google.com/storage/
[Heroku]: https://www.heroku.com/
diff --git a/content/en/commands/hugo_completion_bash.md b/content/en/commands/hugo_completion_bash.md
index ccdd979ae..d77093456 100644
--- a/content/en/commands/hugo_completion_bash.md
+++ b/content/en/commands/hugo_completion_bash.md
@@ -26,7 +26,7 @@ To load completions for every new session, execute once:
#### macOS:
- hugo completion bash > /usr/local/etc/bash_completion.d/hugo
+ hugo completion bash > $(brew --prefix)/etc/bash_completion.d/hugo
You will need to start a new shell for this setup to take effect.
diff --git a/content/en/commands/hugo_completion_zsh.md b/content/en/commands/hugo_completion_zsh.md
index 7dfeab233..7e4e15ac9 100644
--- a/content/en/commands/hugo_completion_zsh.md
+++ b/content/en/commands/hugo_completion_zsh.md
@@ -16,6 +16,10 @@ to enable it. You can execute the following once:
echo "autoload -U compinit; compinit" >> ~/.zshrc
+To load completions in your current shell session:
+
+ source <(hugo completion zsh); compdef _hugo hugo
+
To load completions for every new session, execute once:
#### Linux:
@@ -24,7 +28,7 @@ To load completions for every new session, execute once:
#### macOS:
- hugo completion zsh > /usr/local/share/zsh/site-functions/_hugo
+ hugo completion zsh > $(brew --prefix)/share/zsh/site-functions/_hugo
You will need to start a new shell for this setup to take effect.
diff --git a/content/en/commands/hugo_new.md b/content/en/commands/hugo_new.md
index d294b65b3..5d044b60b 100644
--- a/content/en/commands/hugo_new.md
+++ b/content/en/commands/hugo_new.md
@@ -36,6 +36,7 @@ hugo new [path] [flags]
--disableKinds strings disable different kind of pages (home, RSS etc.)
--editor string edit new content with this editor, if provided
--enableGitInfo add Git revision, date, author, and CODEOWNERS info to the pages
+ -f, --force overwrite file if it already exists
--forceSyncStatic copy all files when static is changed.
--gc enable to run some cleanup tasks (remove unused cache files) after the build
-h, --help help for new
diff --git a/content/en/content-management/_index.md b/content/en/content-management/_index.md
index 28f2ecf82..7cb6357c6 100644
--- a/content/en/content-management/_index.md
+++ b/content/en/content-management/_index.md
@@ -1,20 +1,16 @@
---
title: Content Management
-linktitle: Content Management Overview
+linkTitle: Content Management Overview
description: Hugo makes managing large static sites easy with support for archetypes, content types, menus, cross references, summaries, and more.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
menu:
docs:
- parent: "content-management"
- weight: 1
+ parent: content-management
+ weight: 10
keywords: [source, organization]
categories: [content management]
-weight: 01 #rem
-draft: false
-aliases: [/content/,/content/organization]
toc: false
+weight: 10
+aliases: [/content/,/content/organization]
---
A static site generator needs to extend beyond front matter and a couple of templates to be both scalable and *manageable*. Hugo was designed with not only developers in mind, but also content managers and authors.
diff --git a/content/en/content-management/archetypes.md b/content/en/content-management/archetypes.md
index 354ef0fef..31e229838 100644
--- a/content/en/content-management/archetypes.md
+++ b/content/en/content-management/archetypes.md
@@ -1,20 +1,17 @@
---
title: Archetypes
-linktitle: Archetypes
+linkTitle: Archetypes
description: Archetypes are templates used when creating new content.
-date: 2017-02-01
-publishdate: 2017-02-01
keywords: [archetypes,generators,metadata,front matter]
-categories: ["content management"]
+categories: [content management]
menu:
docs:
- parent: "content-management"
- weight: 70
+ parent: content-management
+ weight: 140
quicklinks:
-weight: 70 #rem
-draft: false
-aliases: [/content/archetypes/]
toc: true
+weight: 140
+aliases: [/content/archetypes/]
---
## What are Archetypes?
@@ -69,7 +66,6 @@ It will create a new newsletter type of content file based on the archetype temp
The above _newsletter type archetype_ illustrates the possibilities: The full Hugo `.Site` and all of Hugo&#39;s template funcs can be used in the archetype file.
-
## Directory based archetypes
Since Hugo `0.49` you can use complete directories as archetype templates. Given this archetype directory:
@@ -90,8 +86,6 @@ hugo new --kind post-bundle posts/my-post
Will create a new folder in `/content/posts/my-post` with the same set of files as in the `post-bundle` archetypes folder. All content files (`index.md` etc.) can contain template logic, and will receive the correct `.Site` for the content's language.
-
-
[archetypes directory]: /getting-started/directory-structure/
[content types]: /content-management/types/
[front matter]: /content-management/front-matter/
diff --git a/content/en/content-management/build-options.md b/content/en/content-management/build-options.md
index 7bbb772df..f798754f1 100644
--- a/content/en/content-management/build-options.md
+++ b/content/en/content-management/build-options.md
@@ -1,19 +1,16 @@
---
title: Build Options
-linktitle: Build Options
+linkTitle: Build Options
description: Build options help define how Hugo must treat a given page when building the site.
-date: 2020-03-02
-publishdate: 2020-03-02
keywords: [build,content,front matter, page resources]
-categories: ["content management"]
+categories: [content management]
menu:
docs:
- parent: "content-management"
- weight: 31
-weight: 31 #rem
-draft: false
-aliases: [/content/build-options/]
+ parent: content-management
+ weight: 70
toc: true
+weight: 70
+aliases: [/content/build-options/]
---
They are stored in a reserved Front Matter object named `_build` with the following defaults:
@@ -26,9 +23,10 @@ _build:
{{< /code-toggle >}}
#### render
+
If `always`, the page will be treated as a published page, holding its dedicated output files (`index.html`, etc...) and permalink.
-{{< new-in "0.76.0" >}} We extended this property from a boolean to an enum in Hugo 0.76.0. Valid values are:
+We extended this property from a boolean to an enum in Hugo 0.76.0. Valid values are:
never
: The page will not be included in any page collection.
@@ -52,13 +50,13 @@ always (default)
: The page will be included in all page collections, e.g. `site.RegularPages`, `$page.Pages`.
local
-: The page will be included in any _local_ page collection, e.g. `$page.RegularPages`, `$page.Pages`. One use case for this would be to create fully navigable, but headless content sections. {{< new-in "0.68.0" >}}
+: The page will be included in any _local_ page collection, e.g. `$page.RegularPages`, `$page.Pages`. One use case for this would be to create fully navigable, but headless content sections.
If true, the page will be treated as part of the project's collections and, when appropriate, returned by Hugo's listing methods (`.Pages`, `.RegularPages` etc...).
#### publishResources
-If set to true the [Bundle's Resources]({{< relref "content-management/page-bundles" >}}) will be published.
+If set to true the [Bundle's Resources]({{< relref "content-management/page-bundles" >}}) will be published.
Setting this to false will still publish Resources on demand (when a resource's `.Permalink` or `.RelPermalink` is invoked from the templates) but will skip the others.
{{% note %}}
@@ -70,6 +68,7 @@ Any page, regardless of their build options, will always be available using the
### Illustrative use cases
#### Not publishing a page
+
Project needs a "Who We Are" content file for Front Matter and body to be used by the homepage but nowhere else.
```yaml
diff --git a/content/en/content-management/comments.md b/content/en/content-management/comments.md
index 5c604fdeb..bb6a8d6ce 100644
--- a/content/en/content-management/comments.md
+++ b/content/en/content-management/comments.md
@@ -1,19 +1,16 @@
---
title: Comments
-linktitle: Comments
+linkTitle: Comments
description: Hugo ships with an internal Disqus template, but this isn't the only commenting system that will work with your new Hugo website.
-date: 2017-02-01
-publishdate: 2017-02-01
keywords: [sections,content,organization]
categories: [project organization, fundamentals]
menu:
docs:
- parent: "content-management"
- weight: 140
-weight: 140 #rem
-draft: false
-aliases: [/extras/comments/]
+ parent: content-management
+ weight: 220
toc: true
+weight: 220
+aliases: [/extras/comments/]
---
Hugo ships with support for [Disqus](https://disqus.com/), a third-party service that provides comment and community capabilities to websites via JavaScript.
@@ -42,7 +39,7 @@ For many websites, this is enough configuration. However, you also have the opti
Disqus has its own [internal template](https://gohugo.io/templates/internal/#disqus) available, to render it add the following code where you want comments to appear:
-```
+```go-html-template
{{ template "_internal/disqus.html" . }}
```
@@ -55,9 +52,10 @@ These are some alternatives to Disqus:
* [Graph Comment](https://graphcomment.com/)
* [Hyvor Talk](https://talk.hyvor.com/) (Available as a service)
* [IntenseDebate](https://intensedebate.com/)
-* [Isso](https://posativ.org/isso/) (Self-hosted, Python) ([tutorial][issotutorial])
+* [Isso](https://isso-comments.de/) (Self-hosted, Python) ([tutorial][issotutorial])
* [Muut](https://muut.com/)
* [Remark42](https://remark42.com/) (Open source, Golang, Easy to run docker)
+* [ReplyBox](https://getreplybox.com/)
* [Staticman](https://staticman.net/)
* [Talkyard](https://blog-comments.talkyard.io/) (Open source, & serverless hosting)
* [Utterances](https://utteranc.es/) (Open source, GitHub comments widget built on GitHub issues)
diff --git a/content/en/content-management/cross-references.md b/content/en/content-management/cross-references.md
index b5dd8a4c3..00fb2d973 100644
--- a/content/en/content-management/cross-references.md
+++ b/content/en/content-management/cross-references.md
@@ -1,31 +1,49 @@
---
title: Links and Cross References
+linkTitle: Links and Cross References
description: Shortcodes for creating links to documents.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-03-31
categories: [content management]
keywords: ["cross references","references", "anchors", "urls"]
menu:
docs:
- parent: "content-management"
- weight: 100
-weight: 100 #rem
-aliases: [/extras/crossreferences/]
+ parent: content-management
+ weight: 170
toc: true
+weight: 170
+aliases: [/extras/crossreferences/]
---
The `ref` and `relref` shortcodes display the absolute and relative permalinks to a document, respectively.
-## Use `ref` and `relref`
+## Use of `ref` and `relref`
-```go-html-template
-{{</* ref "document" */>}}
-{{</* ref "document#anchor" */>}}
-{{</* ref "document.md" */>}}
-{{</* ref "document.md#anchor" */>}}
-{{</* ref "#anchor" */>}}
-{{</* ref "/blog/my-post" */>}}
+The `ref` and `relref` shortcodes require a single parameter: the path to a content document, with or without a file extension, with or without an anchor. Paths without a leading `/` are first resolved relative to the current page, then to the remainder of the site.
+
+```
+.
+└── content
+ ├── about
+ | ├── _index.md
+ | └── credits.md
+ ├── pages
+ | ├── document1.md
+ | └── document2.md // has anchor #anchor
+ ├── products
+ | └── index.md
+ └── blog
+ └── my-post.md
+```
+
+The pages can be referenced as follows:
+
+
+```text
+{{</* ref "document2" */>}} // <- From pages/document1.md, relative path
+{{</* ref "document2#anchor" */>}}
+{{</* ref "document2.md" */>}}
+{{</* ref "document2.md#anchor" */>}}
+{{</* ref "#anchor" */>}} // <- From pages/document2.md
+{{</* ref "/blog/my-post" */>}} // <- From anywhere, absolute path
{{</* ref "/blog/my-post.md" */>}}
{{</* relref "document" */>}}
{{</* relref "document.md" */>}}
@@ -33,15 +51,22 @@ The `ref` and `relref` shortcodes display the absolute and relative permalinks t
{{</* relref "/blog/my-post.md" */>}}
```
-To generate a hyperlink using `ref` or `relref` in markdown:
+index.md can be reference either by its path or by its containing folder without the ending `/`. \_index.md can be referenced only by its containing folder:
-```md
-[About]({{</* ref "/page/about" */>}} "About Us")
+```text
+{{</* ref "/about" */>}} // <- References /about/_index.md
+{{</* ref "/about/_index" */>}} // Raises REF_NOT_FOUND error
+{{</* ref "/about/credits.md" */>}} // <- References /about/credits.md
+
+{{</* ref "/products" */>}} // <- References /products/index.md
+{{</* ref "/products/index" */>}} // <- References /products/index.md
```
-The `ref` and `relref` shortcodes require a single parameter: the path to a content document, with or without a file extension, with or without an anchor.
+To generate a hyperlink using `ref` or `relref` in markdown:
-**Paths without a leading `/` are first resolved relative to the current page, then to the remainder of the site.
+```text
+[About]({{</* ref "/about" */>}} "About Us")
+```
Hugo emits an error or warning if a document cannot be uniquely resolved. The error behavior is configurable; see below.
@@ -116,7 +141,7 @@ produces this HTML:
The behavior can, since Hugo 0.45, be configured in `config.toml`:
-refLinksErrorLevel ("ERROR")
+refLinksErrorLevel ("ERROR")
: When using `ref` or `relref` to resolve page links and a link cannot resolved, it will be logged with this log level. Valid values are `ERROR` (default) or `WARNING`. Any `ERROR` will fail the build (`exit -1`).
refLinksNotFoundURL
diff --git a/content/en/content-management/diagrams.md b/content/en/content-management/diagrams.md
index 243a70fd4..c95548249 100644
--- a/content/en/content-management/diagrams.md
+++ b/content/en/content-management/diagrams.md
@@ -1,25 +1,23 @@
---
title: Diagrams
-date: 2022-02-20
+LinkTitle: Diagrams
+description: Use fenced code blocks and markdown render hooks to display diagrams.
categories: [content management]
keywords: [diagrams,drawing]
menu:
docs:
- parent: "content-management"
- weight: 22
-weight: 22
+ parent: content-management
+ weight: 50
toc: true
+weight: 50
---
-
-
{{< new-in "0.93.0" >}}
-
## GoAT Diagrams (Ascii)
-Hugo! supports [GoAT](https://github.com/bep/goat) natively. This means that this code block:
+Hugo supports [GoAT](https://github.com/bep/goat) natively. This means that this code block:
-````
+````txt
```goat
. . . .--- 1 .-- 1 / 1
/ \ | | .---+ .-+ +
@@ -45,14 +43,9 @@ Will be rendered as:
1 2 3 4 1 2 3 4 1 2 3 4 '--- 4 '-- 4 \ 4
```
-
-
-
-
## Mermaid Diagrams
-Hugo currently does not provide default templates for Mermaid diagrams. But you can easily add your own. One way to do it would be to create ` layouts/_default/_markup/render-codeblock-mermaid.html`:
-
+Hugo currently does not provide default templates for Mermaid diagrams. But you can easily add your own. One way to do it would be to create `layouts/_default/_markup/render-codeblock-mermaid.html`:
```go-html-template
<div class="mermaid">
@@ -61,7 +54,7 @@ Hugo currently does not provide default templates for Mermaid diagrams. But you
{{ .Page.Store.Set "hasMermaid" true }}
```
-And then include this snippet at the bottom of the content template (below `.Content`):
+And then include this snippet at the bottom of the content template (**Note**: below `.Content` as the render hook is not processed until `.Content` is executed):
```go-html-template
{{ if .Page.Store.Get "hasMermaid" }}
@@ -88,8 +81,6 @@ sequenceDiagram
Bob-->>John: Jolly good!
```
-
-
## Goat Ascii Diagram Examples
### Graphics
@@ -160,7 +151,7 @@ sequenceDiagram
### File tree
-Created from https://arthursonzogni.com/Diagon/#Tree
+Created from <https://arthursonzogni.com/Diagon/#Tree>
```goat { width=300 color="orange" }
───Linux─┬─Android
@@ -176,7 +167,7 @@ Created from https://arthursonzogni.com/Diagon/#Tree
### Sequence Diagram
-https://arthursonzogni.com/Diagon/#Sequence
+<https://arthursonzogni.com/Diagon/#Sequence>
```goat { class="w-40" }
┌─────┐ ┌───┐
@@ -197,7 +188,7 @@ https://arthursonzogni.com/Diagon/#Sequence
### Flowchart
-https://arthursonzogni.com/Diagon/#Flowchart
+<https://arthursonzogni.com/Diagon/#Flowchart>
```goat
_________________
@@ -243,7 +234,7 @@ https://arthursonzogni.com/Diagon/#Flowchart
### Table
-https://arthursonzogni.com/Diagon/#Table
+<https://arthursonzogni.com/Diagon/#Table>
```goat { class="w-80 dark-blue" }
┌────────────────────────────────────────────────┐
@@ -272,6 +263,3 @@ https://arthursonzogni.com/Diagon/#Table
│LITERAL = """" character { character } """" .│
└────────────────────────────────────────────────┘
```
-
-
-
diff --git a/content/en/content-management/formats.md b/content/en/content-management/formats.md
index 303bb4596..a98898821 100644
--- a/content/en/content-management/formats.md
+++ b/content/en/content-management/formats.md
@@ -1,19 +1,16 @@
---
title: Content Formats
-linktitle: Content Formats
+linkTitle: Content Formats
description: Both HTML and Markdown are supported content formats.
-date: 2017-01-10
-publishdate: 2017-01-10
categories: [content management]
keywords: [markdown,asciidoc,pandoc,content format]
menu:
docs:
- parent: "content-management"
- weight: 20
-weight: 20 #rem
-draft: false
-aliases: [/content/markdown-extras/,/content/supported-formats/,/doc/supported-formats/]
+ parent: content-management
+ weight: 40
toc: true
+weight: 40
+aliases: [/content/markdown-extras/,/content/supported-formats/,/doc/supported-formats/]
---
You can put any file type into your `/content` directories, but Hugo uses the `markup` front matter value if set or the file extension (see `Markup identifiers` in the table below) to determine if the markup needs to be processed, e.g.:
@@ -28,7 +25,7 @@ The current list of content formats in Hugo:
| Name | Markup identifiers | Comment |
| ------------- | ------------- |-------------|
-| Goldmark | md, markdown, goldmark |Note that you can set the default handler of `md` and `markdown` to something else, see [Configure Markup](/getting-started/configuration-markup/).{{< new-in "0.60.0" >}} |
+| Goldmark | md, markdown, goldmark |Note that you can set the default handler of `md` and `markdown` to something else, see [Configure Markup](/getting-started/configuration-markup/).|
|Emacs Org-Mode|org|See [go-org](https://github.com/niklasfasching/go-org).|
|AsciiDoc|asciidocext, adoc, ad|Needs [Asciidoctor][ascii] installed.|
|RST|rst|Needs [RST](https://docutils.sourceforge.io/rst.html) installed.|
@@ -55,13 +52,13 @@ Because additional formats are external commands, generation performance will re
### External Helper AsciiDoc
-[AsciiDoc](https://github.com/asciidoc/asciidoc) implementation EOLs in Jan 2020 and is no longer supported.
-AsciiDoc development is being continued under [Asciidoctor](https://github.com/asciidoctor). The format AsciiDoc
+[AsciiDoc](https://github.com/asciidoc/asciidoc) implementation EOLs in Jan 2020 and is no longer supported.
+AsciiDoc development is being continued under [Asciidoctor](https://github.com/asciidoctor). The format AsciiDoc
remains of course. Please continue with the implementation Asciidoctor.
### External Helper Asciidoctor
-The Asciidoctor community offers a wide set of tools for the AsciiDoc format that can be installed additionally to Hugo.
+The Asciidoctor community offers a wide set of tools for the AsciiDoc format that can be installed additionally to Hugo.
[See the Asciidoctor docs for installation instructions](https://asciidoctor.org/docs/install-toolchain/). Make sure that also all
optional extensions like `asciidoctor-diagram` or `asciidoctor-html5s` are installed if required.
@@ -100,7 +97,7 @@ Notice that for security concerns only extensions that do not have path separato
Example of how to set extensions and attributes:
-```
+```yml
[markup.asciidocExt]
extensions = ["asciidoctor-html5s", "asciidoctor-diagram"]
workingFolderCurrent = true
@@ -109,10 +106,10 @@ Example of how to set extensions and attributes:
my-attribute-name = "my value"
```
-In a complex Asciidoctor environment it is sometimes helpful to debug the exact call to your external helper with all
+In a complex Asciidoctor environment it is sometimes helpful to debug the exact call to your external helper with all
parameters. Run Hugo with `-v`. You will get an output like
-```
+```txt
INFO 2019/12/22 09:08:48 Rendering book-as-pdf.adoc with C:\Ruby26-x64\bin\asciidoctor.bat using asciidoc args [--no-header-footer -r asciidoctor-html5s -b html5s -r asciidoctor-diagram --base-dir D:\prototypes\hugo_asciidoc_ddd\docs -a outdir=D:\prototypes\hugo_asciidoc_ddd\build -] ...
```
diff --git a/content/en/content-management/front-matter.md b/content/en/content-management/front-matter.md
index 0d8c2e3a6..71e6e36ea 100644
--- a/content/en/content-management/front-matter.md
+++ b/content/en/content-management/front-matter.md
@@ -1,20 +1,17 @@
---
title: Front Matter
-linktitle:
+linkTitle: Front Matter
description: Hugo allows you to add front matter in yaml, toml, or json to your content files.
-date: 2017-01-09
-publishdate: 2017-01-09
lastmod: 2017-02-24
categories: [content management]
keywords: ["front matter", "yaml", "toml", "json", "metadata", "archetypes"]
menu:
docs:
- parent: "content-management"
- weight: 30
-weight: 30 #rem
-draft: false
-aliases: [/content/front-matter/]
+ parent: content-management
+ weight: 60
toc: true
+weight: 60
+aliases: [/content/front-matter/]
---
**Front matter** allows you to keep metadata attached to an instance of a [content type][]---i.e., embedded inside a content file---and is one of the many features that gives Hugo its strength.
@@ -68,7 +65,7 @@ cascade
: a map of Front Matter keys whose values are passed down to the page's descendants unless overwritten by self or a closer ancestor's cascade. See [Front Matter Cascade](#front-matter-cascade) for details.
date
-: the datetime assigned to this page. This is usually fetched from the `date` field in front matter, but this behaviour is configurable.
+: the datetime assigned to this page. This is usually fetched from the `date` field in front matter, but this behavior is configurable.
description
: the description for the content.
@@ -137,7 +134,7 @@ weight
: used for [ordering your content in lists][ordering]. Lower weight gets higher precedence. So content with lower weight will come first. If set, weights should be non-zero, as 0 is interpreted as an *unset* weight.
\<taxonomies\>
-: field name of the *plural* form of the index. See `tags` and `categories` in the above front matter examples. _Note that the plural form of user-defined taxonomies cannot be the same as any of the predefined front matter variables._
+: field name of the *plural* form of the index. See `tags` and `categories` in the above front matter examples. *Note that the plural form of user-defined taxonomies cannot be the same as any of the predefined front matter variables.*
{{% note "Hugo's Default URL Destinations" %}}
If neither `slug` nor `url` is present and [permalinks are not configured otherwise in your site `config` file](/content-management/urls/#permalinks), Hugo will use the filename of your content to create the output URL. See [Content Organization](/content-management/organization) for an explanation of paths in Hugo and [URL Management](/content-management/urls/) for ways to customize Hugo's default behaviors.
@@ -160,9 +157,7 @@ Any node or section can pass down to descendants a set of Front Matter values as
### Target Specific Pages
-{{< new-in "0.76.0" >}}
-
-Since Hugo 0.76 the `cascade` block can be a slice with a optional `_target` keyword, allowing for multiple `cascade` values targeting different page sets.
+The `cascade` block can be a slice with a optional `_target` keyword, allowing for multiple `cascade` values targeting different page sets.
{{< code-toggle copy="false" >}}
title ="Blog"
@@ -181,7 +176,7 @@ kind="section"
Keywords available for `_target`:
path
-: A [Glob](https://github.com/gobwas/glob) pattern matching the content path below /content. Expects Unix-styled slashes. Note that this is the virtual path, so it starts at the mount root. The matching support double-asterisks so you can match for patterns like `/blog/*/**` to match anything from the third level and down.
+: A [Glob](https://github.com/gobwas/glob) pattern matching the content path below /content. Expects Unix-styled slashes. Note that this is the virtual path, so it starts at the mount root. The matching supports double-asterisks so you can match for patterns like `/blog/*/**` to match anything from the third level and down.
kind
: A Glob pattern matching the Page's Kind(s), e.g. "{home,section}".
@@ -192,7 +187,7 @@ lang
environment
: A Glob pattern matching the build environment, e.g. "{production,development}"
-Any of the above can be omitted.
+Any of the above can be omitted.
### Example
@@ -206,11 +201,9 @@ cascade:
With the above example the Blog section page and its descendants will return `images/typewriter.jpg` when `.Params.banner` is invoked unless:
-- Said descendant has its own `banner` value set
+- Said descendant has its own `banner` value set
- Or a closer ancestor node has its own `cascade.banner` value set.
-
-
## Order Content Through Front Matter
You can assign content-specific `weight` in the front matter of your content. These values are especially useful for [ordering][ordering] in list views. You can use `weight` for ordering of content and the convention of [`<TAXONOMY>_weight`][taxweight] for ordering content within a taxonomy. See [Ordering and Grouping Hugo Lists][lists] to see how `weight` can be used to organize your content in list views.
@@ -221,9 +214,9 @@ It's possible to set some options for Markdown rendering in a content's front ma
## Front Matter Format Specs
-* [TOML Spec][toml]
-* [YAML Spec][yaml]
-* [JSON Spec][json]
+- [TOML Spec][toml]
+- [YAML Spec][yaml]
+- [JSON Spec][json]
[variables]: /variables/
[aliases]: /content-management/urls/#aliases
diff --git a/content/en/content-management/image-processing/index.md b/content/en/content-management/image-processing/index.md
index f2748f5db..3f71b4244 100644
--- a/content/en/content-management/image-processing/index.md
+++ b/content/en/content-management/image-processing/index.md
@@ -1,16 +1,15 @@
---
-title: "Image Processing"
-description: "Resize, crop, rotate, filter, and convert images."
-date: 2018-01-24T13:10:00-05:00
-categories: ["content management"]
+title: Image Processing
+linkTitle: Image Processing
+description: Resize, crop, rotate, filter, and convert images.
+categories: [content management]
keywords: [resources, images]
-weight: 4004
-draft: false
-toc: true
menu:
docs:
- parent: "content-management"
- weight: 32
+ parent: content-management
+ weight: 90
+toc: true
+weight: 90
---
## Image Resources
@@ -28,16 +27,6 @@ content/
└── sunset.jpg <-- page resource
```
-## The Image Resource
-
-The `image` resource gives you access to image-specific attributes like the picture's `Width` and `Height`, as well as powerful processing methods and filters. More on that below.
-
-Note that the `image` resource can also be retrieved from a [global resource]({{< relref "/hugo-pipes/introduction#from-file-to-resource" >}})
-
-```go-html-template
-{{ $image := .Resources.GetMatch "sunset.jpg" }}
-```
-
### Global Resources
A global resource is a file:
@@ -94,10 +83,10 @@ Example 3: A more concise way to skip image rendering if the resource is not fou
## Image Processing Methods
-The `image` resource implements the `Resize`, `Fit`, `Fill`, `Crop`, `Filter`, and `Exif` methods.
+The `image` resource implements the [`Resize`], [`Fit`], [`Fill`], [`Crop`], [`Filter`], [`Colors`] and [`Exif`] methods.
{{% note %}}
-Metadata (Exif, IPTC, XMP, etc.) is not preserved during image transformation. Use the`Exif` method with the _original_ image to extract Exif metadata from JPEG or TIFF images.
+Metadata (Exif, IPTC, XMP, etc.) is not preserved during image transformation. Use the [`Exif`] method with the _original_ image to extract Exif metadata from JPEG or TIFF images.
{{% /note %}}
### Resize
@@ -163,11 +152,24 @@ Sometimes it can be useful to create the filter chain once and then reuse it.
{{ $image2 := $image2.Filter $filters }}
```
+### Colors
+
+{{< new-in "0.104.0" >}}
+
+`.Colors` returns a slice of hex strings with the dominant colors in the image using a simple histogram method.
+
+```go-html-template
+{{ $colors := $image.Colors }}
+```
+
+This method is fast, but if you also scale down your images, it would be good for performance to extract the colors from the scaled down image.
+
+
### Exif
Provides an [Exif] object containing image metadata.
-You may access Exif data in JPEG and TIFF images. To prevent errors when processing images without Exif data, wrap the access in a `with` statement.
+You may access Exif data in JPEG and TIFF images. To prevent errors when processing images without Exif data, wrap the access in a [`with`] statement.
```go-html-template
{{ with $image.Exif }}
@@ -213,11 +215,11 @@ You may also access Exif fields individually, using the [`lang.FormatNumber`] fu
## Image Processing Options
-The `Resize`, `Fit`, `Fill`, and `Crop` methods accept a space-separated, case-insensitive list of options. The order of the options within the list is irrelevant.
+The [`Resize`], [`Fit`], [`Fill`], and [`Crop`] methods accept a space-separated, case-insensitive list of options. The order of the options within the list is irrelevant.
### Dimensions
-With the `Resize` method you must specify width, height, or both. The `Fit`, `Fill`, and `Crop` methods require both width and height. All dimensions are in pixels.
+With the [`Resize`] method you must specify width, height, or both. The [`Fit`], [`Fill`], and [`Crop`] methods require both width and height. All dimensions are in pixels.
```go-html-template
{{ $image := $image.Resize "600x" }}
@@ -252,9 +254,9 @@ In the example above, on the second line, we have reversed width and height to r
### Anchor
-When using the `Crop` or `Fill` method, the _anchor_ determines the placement of the crop box. You may specify `TopLeft`, `Top`, `TopRight`, `Left`, `Center`,`Right`, `BottomLeft`, `Bottom`, `BottomRight`, or `Smart`.
+When using the [`Crop`] or [`Fill`] method, the _anchor_ determines the placement of the crop box. You may specify `TopLeft`, `Top`, `TopRight`, `Left`, `Center`,`Right`, `BottomLeft`, `Bottom`, `BottomRight`, or `Smart`.
-The default value is `Smart`, which uses [Smartcrop] image analysis to determine the optimal placement of the crop box. You may override the default value in the [site configuration](#processing-options).
+The default value is `Smart`, which uses [Smartcrop] image analysis to determine the optimal placement of the crop box. You may override the default value in the [site configuration].
For example, if you have a 400x200 image with a bird in the upper left quadrant, you can create a 200x100 thumbnail containing the bird:
@@ -262,7 +264,7 @@ For example, if you have a 400x200 image with a bird in the upper left quadrant,
{{ $image.Crop "200x100 TopLeft" }}
```
-If you apply rotation when using the `Crop` or `Fill` method, specify the anchor relative to the rotated image.
+If you apply [rotation](#rotation) when using the [`Crop`] or [`Fill`] method, specify the anchor relative to the rotated image.
### Target Format
@@ -286,7 +288,7 @@ To convert an image without scaling, use the dimensions of the original image:
Applicable to JPEG and WebP images, the `q` value determines the quality of the converted image. Higher values produce better quality images, while lower values produce smaller files. Set this value to a whole number between 1 and 100, inclusive.
-The default value is 75. You may override the default value in the [site configuration](#processing-options).
+The default value is 75. You may override the default value in the [site configuration].
```go-html-template
{{ $image.Resize "600x webp q50" }}
@@ -296,7 +298,7 @@ The default value is 75. You may override the default value in the [site configu
<!-- Specifies a libwebp preset, not a libwebp image hint. -->
-Applicable to WebP images, this option corresponds to a set of pre-defined encoding parameters.
+Applicable to WebP images, this option corresponds to a set of predefined encoding parameters.
Value|Example
:--|:--
@@ -306,7 +308,7 @@ Value|Example
`picture`|Indoor photograph such as a portrait
`text`|Image that is primarily text
-The default value is `photo`. You may override the default value in the [site configuration](#processing-options).
+The default value is `photo`. You may override the default value in the [site configuration].
```go-html-template
{{ $image.Resize "600x webp picture" }}
@@ -318,7 +320,7 @@ When converting an image from a format that supports transparency (e.g., PNG) to
Use either a 3-digit or a 6-digit hexadecimal color code (e.g., `#00f` or `#0000ff`).
-The default value is `#ffffff` (white). You may override the default value in the [site configuration](#processing-options).
+The default value is `#ffffff` (white). You may override the default value in the [site configuration].
```go-html-template
{{ $image.Resize "600x jpg #b31280" }}
@@ -337,7 +339,7 @@ Filter|Description
`Linear`|Bilinear resampling filter, produces smooth output, faster than cubic filters
`NearestNeighbor`|Fastest resampling filter, no antialiasing
-The default value is `Box`. You may override the default value in the [site configuration](#processing-options).
+The default value is `Box`. You may override the default value in the [site configuration].
```go-html-template
{{ $image.Resize "600x400 Lanczos" }}
@@ -364,10 +366,10 @@ _The photo of the sunset used in the examples below is Copyright [Bjørn Erik Pe
This is the shortcode used to generate the examples above:
{{< code file="layouts/shortcodes/imgproc.html" >}}
-{{< readfile file="layouts/shortcodes/imgproc.html" >}}
+{{< readfile file="layouts/shortcodes/imgproc.html" >}}
{{< /code >}}
-Call the shortcode from your markdown like this:
+Call the shortcode from your Markdown like this:
```go-html-template
{{</* imgproc sunset Resize "300x" /*/>}}
@@ -464,3 +466,12 @@ hugo --gc
[page bundle]: {{< relref "content-management/page-bundles" >}}
[Smartcrop]: <https://github.com/muesli/smartcrop#smartcrop>
[time.Format]: {{< relref "functions/dateformat" >}}
+[`Colors`]: #colors
+[`Crop`]: #crop
+[`Exif`]: #exif
+[`Fill`]: #fill
+[`Filter`]: #filter
+[`Fit`]: #fit
+[`Resize`]: #resize
+[site configuration]: #processing-options
+[`with`]: /functions/with/
diff --git a/content/en/content-management/menus.md b/content/en/content-management/menus.md
index aefc99e00..b9fab2ca4 100644
--- a/content/en/content-management/menus.md
+++ b/content/en/content-management/menus.md
@@ -1,20 +1,16 @@
---
title: Menus
-linktitle: Menus
+linkTitle: Menus
description: Hugo has a simple yet powerful menu system.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-03-31
categories: [content management]
keywords: [menus]
-draft: false
menu:
docs:
- parent: "content-management"
- weight: 120
-weight: 120
-aliases: [/extras/menus/]
+ parent: content-management
+ weight: 190
toc: true
+weight: 190
+aliases: [/extras/menus/]
---
{{% note "Lazy Blogger"%}}
@@ -69,7 +65,7 @@ menu:
## Add Non-content Entries to a Menu
-You can also add entries to menus that aren’t attached to a piece of content. This takes place in your Hugo project's [`config` file][config].
+You can also add entries to menus that aren’t attached to a piece of content. This takes place in your Hugo project's [`config` file][config] (see [Menu Entry Properties][me-props] for full details of available variables).
Here’s an example snippet pulled from a configuration file:
diff --git a/content/en/content-management/multilingual.md b/content/en/content-management/multilingual.md
index e2450bb29..e1343144e 100644
--- a/content/en/content-management/multilingual.md
+++ b/content/en/content-management/multilingual.md
@@ -1,19 +1,16 @@
---
title: Multilingual Mode
-linktitle: Multilingual
+linkTitle: Multilingual
description: Hugo supports the creation of websites with multiple languages side by side.
-date: 2017-01-10
-publishdate: 2017-01-10
categories: [content management]
keywords: [multilingual,i18n, internationalization]
menu:
docs:
- parent: "content-management"
- weight: 150
-weight: 150 #rem
-draft: false
-aliases: [/content/multilingual/,/tutorials/create-a-multilingual-site/]
+ parent: content-management
+ weight: 230
toc: true
+weight: 230
+aliases: [/content/multilingual/,/tutorials/create-a-multilingual-site/]
---
You should define the available languages in a `languages` section in your site configuration.
@@ -59,7 +56,7 @@ weight = 3
Anything not defined in a `languages` block will fall back to the global value for that key (e.g., `copyright` for the English `en` language). This also works for `params`, as demonstrated with `help` above: You will get the value `Aide` in French and `Help` in all the languages without this parameter set.
-With the configuration above, all content, sitemap, RSS feeds, paginations,
+With the configuration above, all content, sitemap, RSS feeds, pagination,
and taxonomy pages will be rendered below `/` in English (your default content language) and then below `/fr` in French.
When working with front matter `Params` in [single page templates], omit the `params` in the key for the translation.
@@ -229,7 +226,7 @@ If using `url`, remember to include the language part as well: `/fr/compagnie/a-
### Page Bundles
-To avoid the burden of having to duplicate files, each Page Bundle inherits the resources of its linked translated pages' bundles except for the content files (markdown files, html files etc...).
+To avoid the burden of having to duplicate files, each Page Bundle inherits the resources of its linked translated pages' bundles except for the content files (Markdown files, HTML files etc...).
Therefore, from within a template, the page will have access to the files from all linked pages' bundles.
@@ -507,6 +504,7 @@ The rendering of the main navigation works as usual. `.Site.Menus` will just con
```
### Dynamically localizing menus with i18n
+
While customizing menus per language is useful, your config file can become hard to maintain if you have a lot of languages
If your menus are the same in all languages (ie. if the only thing that changes is the translated name) you can use the `.Identifier` as a translation key for the menu name:
@@ -538,7 +536,6 @@ And do the appropriate changes in the menu code to use the `i18n` tag with the `
{{- end }}
</ul>
{{< /code >}}
-
## Missing Translations
@@ -570,9 +567,8 @@ If there is more than one language defined, the `LanguagePrefix` variable will e
## Generate multilingual content with `hugo new`
-Currently, `hugo new` is not ready to support generating multilingual content. But there is a [proposal topic](https://github.com/gohugoio/hugo/issues/7732) about this in Github issue to discuss how it should work.
-
+Currently, `hugo new` is not ready to support generating multilingual content. But there is a [proposal topic](https://github.com/gohugoio/hugo/issues/7732) about this in GitHub issue to discuss how it should work.
[abslangurl]: /functions/abslangurl
[config]: /getting-started/configuration/
diff --git a/content/en/content-management/organization/index.md b/content/en/content-management/organization/index.md
index 10e22c2d3..b677d8c18 100644
--- a/content/en/content-management/organization/index.md
+++ b/content/en/content-management/organization/index.md
@@ -1,20 +1,16 @@
---
title: Content Organization
-linktitle: Organization
+linkTitle: Organization
description: Hugo assumes that the same structure that works to organize your source content is used to organize the rendered site.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [content management,fundamentals]
keywords: [sections,content,organization,bundle,resources]
menu:
docs:
- parent: "content-management"
- weight: 10
-weight: 10 #rem
-draft: false
-aliases: [/content/sections/]
+ parent: content-management
+ weight: 20
toc: true
+weight: 20
+aliases: [/content/sections/]
---
## Page Bundles
@@ -35,14 +31,13 @@ The bundle documentation is a **work in progress**. We will publish more compreh
## Organization of Content Source
-
In Hugo, your content should be organized in a manner that reflects the rendered website.
While Hugo supports content nested at any level, the top levels (i.e. `content/<DIRECTORIES>`) are special in Hugo and are considered the content type used to determine layouts etc. To read more about sections, including how to nest them, see [sections][].
Without any additional configuration, the following will automatically work:
-```
+```txt
.
└── content
└── about
@@ -73,7 +68,7 @@ The following demonstrates the relationships between your content organization a
You can create one `_index.md` for your homepage and one in each of your content sections, taxonomies, and taxonomy terms. The following shows typical placement of an `_index.md` that would contain content and front matter for a `posts` section list page on a Hugo website:
-```
+```txt
. url
. ⊢--^-⊣
. path slug
@@ -85,7 +80,7 @@ content/posts/_index.md
At build, this will output to the following destination with the associated values:
-```
+```txt
url ("/posts/")
⊢-^-⊣
@@ -104,7 +99,7 @@ The [sections] can be nested as deeply as you want. The important thing to under
Single content files in each of your sections will be rendered as [single page templates][singles]. Here is an example of a single `post` within `posts`:
-```
+```txt
path ("posts/my-first-hugo-post.md")
. ⊢-----------^------------⊣
. section slug
@@ -114,7 +109,7 @@ content/posts/my-first-hugo-post.md
When Hugo builds your site, the content will be output to the following destination:
-```
+```txt
url ("/posts/my-first-hugo-post/")
⊢------------^----------⊣
@@ -180,7 +175,7 @@ slug: "new-post"
This will render to the following destination according to Hugo's default behavior:
-```
+```txt
example.com/posts/new-post/
```
@@ -217,7 +212,7 @@ url: /blog/new-url/
Assuming your `baseURL` is [configured][config] to `https://example.com`, the addition of `url` to the front matter will make `old-url.md` render to the following destination:
-```
+```txt
https://example.com/blog/new-url/
```
diff --git a/content/en/content-management/page-bundles.md b/content/en/content-management/page-bundles.md
index 924efccd2..28ab004c5 100644
--- a/content/en/content-management/page-bundles.md
+++ b/content/en/content-management/page-bundles.md
@@ -1,16 +1,17 @@
---
-title : "Page Bundles"
-description : "Content organization using Page Bundles"
-date : 2018-01-24T13:09:00-05:00
-linktitle : "Page Bundles"
-keywords : ["page", "bundle", "leaf", "branch"]
-categories : ["content management"]
-toc : true
+title: Page Bundles
+linkTitle: Page Bundles
+description: Content organization using Page Bundles
+linkTitle: Page Bundles
+keywords: [page, bundle, leaf, branch]
+categories: [content management]
menu :
docs:
- identifier : "page-bundles"
- parent : "content-management"
- weight : 11
+ identifier: "page-bundles"
+ parent: "content-management"
+ weight: 30
+toc: true
+weight: 30
---
Page Bundles are a way to group [Page Resources](/content-management/page-resources/).
@@ -23,8 +24,8 @@ A Page Bundle can be one of:
| | Leaf Bundle | Branch Bundle |
|-------------------------------------|----------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Usage | Collection of content and attachments for single pages | Collection of attachments for section pages (home page, section, taxonomy terms, taxonomy list) |
-| Index file name | `index.md` [^fn:1] | `_index.md` [^fn:1] |
-| Allowed Resources | Page and non-page (like images, pdf, etc.) types | Only non-page (like images, pdf, etc.) types |
+| Index filename | `index.md` [^fn:1] | `_index.md` [^fn:1] |
+| Allowed Resources | Page and non-page (like images, PDF, etc.) types | Only non-page (like images, PDF, etc.) types |
| Where can the Resources live? | At any directory level within the leaf bundle directory. | Only in the directory level **of** the branch bundle directory i.e. the directory containing the `_index.md` ([ref](https://discourse.gohugo.io/t/question-about-content-folder-structure/11822/4?u=kaushalmodi)). |
| Layout type | `single` | `list` |
| Nesting | Does not allow nesting of more bundles under it | Allows nesting of leaf or branch bundles under it |
@@ -72,13 +73,13 @@ bundles:
: This leaf bundle has the `index.md`, two other content
Markdown files and two image files.
-- image1, image2:
+- image1, image2:
These images are page resources of `my-post`
and only available in `my-post/index.md` resources.
-- content1, content2:
+- content1, content2:
These content files are page resources of `my-post`
- and only available in `my-post/index.md` resources.
+ and only available in `my-post/index.md` resources.
They will **not** be rendered as individual pages.
`my-other-post`
@@ -99,8 +100,8 @@ as long as it is not inside another **leaf** bundle.
A headless bundle is a bundle that is configured to not get published
anywhere:
-- It will have no `Permalink` and no rendered HTML in `public/`.
-- It will not be part of `.Site.RegularPages`, etc.
+- It will have no `Permalink` and no rendered HTML in `public/`.
+- It will not be part of `.Site.RegularPages`, etc.
But you can get it by `.Site.GetPage`. Here is an example:
@@ -121,9 +122,9 @@ _In this example, we are assuming the `some-headless-bundle` to be a headless
Explanation of the above example:
1. Get the `some-headless-bundle` Page "object".
-2. Collect a *slice* of resources in this *Page Bundle* that matches
+2. Collect a _slice_ of resources in this _Page Bundle_ that matches
`"author*"` using `.Resources.Match`.
-3. Loop through that *slice* of nested pages, and output their `.Title` and
+3. Loop through that _slice_ of nested pages, and output their `.Title` and
`.Content`.
---
@@ -137,9 +138,8 @@ headless = true
There are many use cases of such headless page bundles:
-- Shared media galleries
-- Reusable page content "snippets"
-
+- Shared media galleries
+- Reusable page content "snippets"
## Branch Bundles {#branch-bundles}
diff --git a/content/en/content-management/page-resources.md b/content/en/content-management/page-resources.md
index 24b1d03ed..16c9fc0ab 100644
--- a/content/en/content-management/page-resources.md
+++ b/content/en/content-management/page-resources.md
@@ -1,17 +1,15 @@
---
-title : "Page Resources"
-description : "Page resources -- images, other pages, documents, etc. -- have page-relative URLs and their own metadata."
-date: 2018-01-24
-categories: ["content management"]
+title: Page Resources
+linkTitle: Page Resources
+description: Page resources -- images, other pages, documents, etc. -- have page-relative URLs and their own metadata.
+categories: [content management]
keywords: [bundle,content,resources]
-weight: 4003
-draft: false
-toc: true
-linktitle: "Page Resources"
menu:
docs:
- parent: "content-management"
- weight: 31
+ parent: content-management
+ weight: 80
+toc: true
+weight: 80
---
Page resources are only accessible from [page bundles]({{< relref
"/content-management/page-bundles" >}}), those directories with `index.md` or
@@ -45,8 +43,6 @@ content
ResourceType
: The main type of the resource's [Media Type](/templates/output-formats/#media-types). For example, a file of MIME type `image/jpeg` has the ResourceType `image`. A `Page` will have `ResourceType` with value `page`.
-{{< new-in "0.80.0" >}} Note that we in Hugo `v0.80.0` fixed a bug where non-image resources (e.g. video) would return the MIME sub type, e.g. `json`.
-
Name
: Default value is the filename (relative to the owning page). Can be set in front matter.
@@ -90,16 +86,17 @@ MediaType.Suffixes
: A slice of possible suffixes for the resource's MIME type.
## Methods
+
ByType
: Returns the page resources of the given type.
-```go
+```go-html-template
{{ .Resources.ByType "image" }}
```
Match
: Returns all the page resources (as a slice) whose `Name` matches the given Glob pattern ([examples](https://github.com/gobwas/glob/blob/master/readme.md)). The matching is case-insensitive.
-```go
+```go-html-template
{{ .Resources.Match "images/*" }}
```
@@ -107,6 +104,7 @@ GetMatch
: Same as `Match` but will return the first match.
### Pattern Matching
+
```go
// Using Match/GetMatch to find this images/sunset.jpg ?
.Resources.Match "images/sun*" ✅
@@ -140,8 +138,7 @@ title
params
: A map of custom key/values.
-
-### Resources metadata example
+### Resources metadata example
{{< code-toggle copy="false">}}
title: Application
diff --git a/content/en/content-management/related.md b/content/en/content-management/related.md
index 9ede15252..2d2077c81 100644
--- a/content/en/content-management/related.md
+++ b/content/en/content-management/related.md
@@ -1,25 +1,22 @@
---
title: Related Content
+linkTitle: Related Content
description: List related content in "See Also" sections.
-date: 2017-09-05
categories: [content management]
keywords: [content]
menu:
docs:
- parent: "content-management"
- weight: 40
-weight: 30
-draft: false
-aliases: [/content/related/,/related/]
+ parent: content-management
+ weight: 110
toc: true
+weight: 110
+aliases: [/content/related/,/related/]
---
-
Hugo uses a set of factors to identify a page's related content based on Front Matter parameters. This can be tuned to the desired set of indices and parameters or left to Hugo's default [Related Content configuration](#configure-related-content).
## List Related Content
-
To list up to 5 related pages (which share the same _date_ or _keyword_ parameters) is as simple as including something similar to this partial in your single page template:
{{< code file="layouts/partials/related.html" >}}
@@ -27,9 +24,9 @@ To list up to 5 related pages (which share the same _date_ or _keyword_ paramete
{{ with $related }}
<h3>See Also</h3>
<ul>
- {{ range . }}
- <li><a href="{{ .RelPermalink }}">{{ .Title }}</a></li>
- {{ end }}
+ {{ range . }}
+ <li><a href="{{ .RelPermalink }}">{{ .Title }}</a></li>
+ {{ end }}
</ul>
{{ end }}
{{< /code >}}
@@ -39,25 +36,28 @@ To list up to 5 related pages (which share the same _date_ or _keyword_ paramete
Here is the list of "Related" methods available on a page collection such `.RegularPages`.
#### .Related PAGE
+
Returns a collection of pages related the given one.
-```
+```go-html-template
{{ $related := site.RegularPages.Related . }}
```
#### .RelatedIndices PAGE INDICE1 [INDICE2 ...]
+
Returns a collection of pages related to a given one restricted to a list of indices.
-```
+```go-html-template
{{ $related := site.RegularPages.RelatedIndices . "tags" "date" }}
```
#### .RelatedTo KEYVALS [KEYVALS2 ...]
+
Returns a collection of pages related together by a set of indices and their match.
In order to build those set and pass them as argument, one must use the `keyVals` function where the first argument would be the `indice` and the consecutive ones its potential `matches`.
-```
+```go-html-template
{{ $related := site.RegularPages.RelatedTo ( keyVals "tags" "hugo" "rocks") ( keyVals "date" .Date ) }}
```
@@ -66,6 +66,7 @@ Read [this blog article](https://regisphilibert.com/blog/2018/04/hugo-optmized-r
{{% /note %}}
## Configure Related Content
+
Hugo provides a sensible default configuration of Related Content, but you can fine-tune this in your configuration, on the global or language level if needed.
### Default configuration
diff --git a/content/en/content-management/sections.md b/content/en/content-management/sections.md
index 6806e342c..4335f137d 100644
--- a/content/en/content-management/sections.md
+++ b/content/en/content-management/sections.md
@@ -1,7 +1,7 @@
---
title: Content Sections
-linktitle: Sections
-description: "Hugo generates a **section tree** that matches your content."
+linkTitle: Sections
+description: Hugo generates a **section tree** that matches your content.
date: 2017-02-01
publishdate: 2017-02-01
lastmod: 2017-02-01
@@ -9,12 +9,11 @@ categories: [content management]
keywords: [lists,sections,content types,organization]
menu:
docs:
- parent: "content-management"
- weight: 50
-weight: 50 #rem
-draft: false
-aliases: [/content/sections/]
+ parent: content-management
+ weight: 120
toc: true
+weight: 120
+aliases: [/content/sections/]
---
A **Section** is a collection of pages that gets defined based on the
@@ -73,7 +72,7 @@ With the available [section variables and methods](#section-page-variables-and-m
{{ else if not .p1.IsHome }}
{{ template "breadcrumbnav" (dict "p1" .p1.Site.Home "p2" .p2 ) }}
{{ end }}
-<li{{ if eq .p1 .p2 }} class="active"{{ end }}>
+<li{{ if eq .p1 .p2 }} class="active" aria-current="page" {{ end }}>
<a href="{{ .p1.Permalink }}">{{ .p1.Title }}</a>
</li>
{{ end }}
@@ -87,7 +86,7 @@ Also see [Page Variables](/variables/page/).
## Content Section Lists
-Hugo will automatically create pages for each *root section* that list all of the content in that section. See the documentation on [section templates][] for details on customizing the way these pages are rendered.
+Hugo will automatically create a page for each *root section* that lists all the content in that section. See the documentation on [section templates][] for details on customizing the way these pages are rendered.
## Content *Section* vs Content *Type*
diff --git a/content/en/content-management/shortcodes.md b/content/en/content-management/shortcodes.md
index 017267ec7..4bc425ff3 100644
--- a/content/en/content-management/shortcodes.md
+++ b/content/en/content-management/shortcodes.md
@@ -1,21 +1,17 @@
---
title: Shortcodes
-linktitle:
+linkTitle: Shortcodes
description: Shortcodes are simple snippets inside your content files calling built-in or custom templates.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2019-11-07
-menu:
- docs:
- parent: "content-management"
- weight: 35
-weight: 35 #rem
categories: [content management]
keywords: [markdown,content,shortcodes]
-draft: false
+menu:
+ docs:
+ parent: content-management
+ weight: 100
+toc: true
+weight: 100
aliases: [/extras/shortcodes/]
testparam: "Hugo Rocks!"
-toc: true
---
## What a Shortcode is
@@ -40,11 +36,11 @@ Some shortcodes use or require closing shortcodes. Again like HTML, the opening
Here are two examples of paired shortcodes:
-```
+```go-html-template
{{%/* mdshortcode */%}}Stuff to `process` in the *center*.{{%/* /mdshortcode */%}}
```
-```
+```go-html-template
{{</* highlight go */>}} A bunch of code here {{</* /highlight */>}}
```
@@ -52,11 +48,9 @@ The examples above use two different delimiters, the difference being the `%` ch
### Shortcodes with raw string parameters
-{{< new-in "0.64.1" >}}
-
You can pass multiple lines as parameters to a shortcode by using raw string literals:
-```
+```go-html-template
{{</* myshortcode `This is some <b>HTML</b>,
and a new line with a "quoted string".` */>}}
```
@@ -67,16 +61,15 @@ In Hugo `0.55` we changed how the `%` delimiter works. Shortcodes using the `%`
If you want the old behavior, you can put the following line in the start of your shortcode template:
-```
+```go-html-template
{{ $_hugo_config := `{ "version": 1 }` }}
```
-
### Shortcodes Without Markdown
-The `<` character indicates that the shortcode's inner content does *not* need further rendering. Often shortcodes without markdown include internal HTML:
+The `<` character indicates that the shortcode's inner content does *not* need further rendering. Often shortcodes without Markdown include internal HTML:
-```
+```go-html-template
{{</* myshortcode */>}}<p>Hello <strong>World!</strong></p>{{</* /myshortcode */>}}
```
@@ -86,11 +79,11 @@ You can call shortcodes within other shortcodes by creating your own templates t
## Use Hugo's Built-in Shortcodes
-Hugo ships with a set of predefined shortcodes that represent very common usage. These shortcodes are provided for author convenience and to keep your markdown content clean.
+Hugo ships with a set of predefined shortcodes that represent very common usage. These shortcodes are provided for author convenience and to keep your Markdown content clean.
### `figure`
-`figure` is an extension of the image syntax in markdown, which does not provide a shorthand for the more semantic [HTML5 `<figure>` element][figureelement].
+`figure` is an extension of the image syntax in Markdown, which does not provide a shorthand for the more semantic [HTML5 `<figure>` element][figureelement].
The `figure` shortcode can use the following named parameters:
@@ -151,13 +144,13 @@ attrlink
Bloggers often want to include GitHub gists when writing posts. Let's suppose we want to use the [gist at the following url][examplegist]:
-```
+```txt
https://gist.github.com/spf13/7896402
```
We can embed the gist in our content via username and gist ID pulled from the URL:
-```
+```go-html-template
{{</* gist spf13 7896402 */>}}
```
@@ -177,7 +170,7 @@ If the gist contains several files and you want to quote just one of them, you c
#### Example `gist` Display
-To demonstrate the remarkably efficiency of Hugo's shortcode feature, we have embedded the `spf13` `gist` example in this page. The following simulates the experience for visitors to your website. Naturally, the final display will be contingent on your stylesheets and surrounding markup.
+To demonstrate the remarkable efficiency of Hugo's shortcode feature, we have embedded the `spf13` `gist` example in this page. The following simulates the experience for visitors to your website. Naturally, the final display will depend on your stylesheets and surrounding markup.
{{< gist spf13 7896402 >}}
@@ -223,7 +216,7 @@ To see even more options for adding syntax-highlighted code blocks to your websi
If you'd like to embed a photo from [Instagram][], you only need the photo's ID. You can discern an Instagram photo ID from the URL:
-```
+```txt
https://www.instagram.com/p/BWNjjyYFxVx/
```
@@ -249,19 +242,18 @@ By adding the preceding `hidecaption` example, the following HTML will be added
#### Example `instagram` Display
-Using the preceding `instagram` with `hidecaption` example above, the following simulates the displayed experience for visitors to your website. Naturally, the final display will be contingent on your stylesheets and surrounding markup.
+Using the preceding `instagram` with `hidecaption` example above, the following simulates the displayed experience for visitors to your website. Naturally, the final display will be contingent on your style sheets and surrounding markup.
{{< instagram BWNjjyYFxVx hidecaption >}}
-
{{% note %}}
The `instagram`-shortcode refers an endpoint of Instagram's API, that's deprecated since October 24th, 2020. Thus, no images can be fetched from this API endpoint, resulting in an error when the `instagram`-shortcode is used. For more information please have a look at GitHub issue [#7879](https://github.com/gohugoio/hugo/issues/7879).
{{% /note %}}
### `param`
-Gets a value from the current `Page's` params set in front matter, with a fall back to the site param value. It will log an `ERROR` if the param with the given key could not be found in either.
+Gets a value from the current `Page's` params set in front matter, with a fallback to the site param value. It will log an `ERROR` if the param with the given key could not be found in either.
```bash
{{</* param testparam */>}}
@@ -291,7 +283,7 @@ Read a more extensive description of `ref` and `relref` in the [cross references
#### Example `ref` and `relref` Input
-```
+```go-html-template
[Neat]({{</* ref "blog/neat.md" */>}})
[Who]({{</* relref "about.md#who" */>}})
```
@@ -300,7 +292,7 @@ Read a more extensive description of `ref` and `relref` in the [cross references
Assuming that standard Hugo pretty URLs are turned on.
-```
+```html
<a href="https://example.com/blog/neat">Neat</a>
<a href="/about/#who">Who</a>
```
@@ -309,13 +301,13 @@ Assuming that standard Hugo pretty URLs are turned on.
You want to include a single tweet into your blog post? Everything you need is the URL of the tweet:
-```
+```txt
https://twitter.com/SanDiegoZoo/status/1453110110599868418
```
#### Example `tweet` Input
-Pass the tweet's user (case-insensitive) and id from the URL as parameters to the `tweet` shortcode.
+Pass the tweet's user (case-insensitive) and ID from the URL as parameters to the `tweet` shortcode.
{{< code file="example-tweet-input.md" >}}
{{</* tweet user="SanDiegoZoo" id="1453110110599868418" */>}}
@@ -339,7 +331,7 @@ Using the preceding `tweet` example, the following simulates the displayed exper
Adding a video from [Vimeo][] is equivalent to the [YouTube Input shortcode][].
-```
+```txt
https://vimeo.com/channels/staffpicks/146022717
```
@@ -360,9 +352,9 @@ Using the preceding `vimeo` example, the following HTML will be added to your re
{{< /output >}}
{{% tip %}}
-If you want to further customize the visual styling of the YouTube or Vimeo output, add a `class` named parameter when calling the shortcode. The new `class` will be added to the `<div>` that wraps the `<iframe>` *and* will remove the inline styles. Note that you will need to call the `id` as a named parameter as well. You can also give the vimeo video a descriptive title with `title`.
+If you want to further customize the visual styling of the YouTube or Vimeo output, add a `class` named parameter when calling the shortcode. The new `class` will be added to the `<div>` that wraps the `<iframe>` *and* will remove the inline styles. Note that you will need to call the `id` as a named parameter as well. You can also give the vimeo video a descriptive title with `title`.
-```
+```go
{{</* vimeo id="146022717" class="my-vimeo-wrapper-class" title="My vimeo video" */>}}
```
{{% /tip %}}
@@ -377,11 +369,10 @@ Using the preceding `vimeo` example, the following simulates the displayed exper
The `youtube` shortcode embeds a responsive video player for [YouTube videos][]. Only the ID of the video is required, e.g.:
-```
+```txt
https://www.youtube.com/watch?v=w7Ft2ymGmfc
```
-
#### Example `youtube` Input
Copy the YouTube video ID that follows `v=` in the video's URL and pass it to the `youtube` shortcode:
@@ -390,7 +381,7 @@ Copy the YouTube video ID that follows `v=` in the video's URL and pass it to th
{{</* youtube w7Ft2ymGmfc */>}}
{{< /code >}}
-Furthermore, you can automatically start playback of the embedded video by setting the `autoplay` parameter to `true`. Remember that you can't mix named and unnamed parameters, so you'll need to assign the yet unnamed video id to the parameter `id`:
+Furthermore, you can automatically start playback of the embedded video by setting the `autoplay` parameter to `true`. Remember that you can't mix named and unnamed parameters, so you'll need to assign the yet unnamed video ID to the parameter `id`:
{{< code file="example-youtube-input-with-autoplay.md" >}}
@@ -403,7 +394,6 @@ For [accessibility reasons](https://dequeuniversity.com/tips/provide-iframe-titl
{{</* youtube id="w7Ft2ymGmfc" title="A New Hugo Site in Under Two Minutes" */>}}
{{< /code >}}
-
#### Example `youtube` Output
Using the preceding `youtube` example, the following HTML will be added to your rendered website's markup:
@@ -414,7 +404,7 @@ Using the preceding `youtube` example, the following HTML will be added to your
#### Example `youtube` Display
-Using the preceding `youtube` example (without `autoplay="true"`), the following simulates the displayed experience for visitors to your website. Naturally, the final display will be contingent on your stylesheets and surrounding markup. The video is also include in the [Quick Start of the Hugo documentation][quickstart].
+Using the preceding `youtube` example (without `autoplay="true"`), the following simulates the displayed experience for visitors to your website. Naturally, the final display will be contingent on your style sheets and surrounding markup. The video is also include in the [Quick Start of the Hugo documentation][quickstart].
{{< youtube w7Ft2ymGmfc >}}
diff --git a/content/en/content-management/static-files.md b/content/en/content-management/static-files.md
index e42ee9088..946919f0a 100644
--- a/content/en/content-management/static-files.md
+++ b/content/en/content-management/static-files.md
@@ -1,16 +1,16 @@
---
title: Static Files
-description: "Files that get served **statically** (as-is, no modification) on the site root."
-date: 2017-11-18
+linkTitle: Static Files
+description: Files that get served **statically** (as-is, no modification) on the site root.
categories: [content management]
keywords: [source, directories]
menu:
docs:
- parent: "content-management"
- weight: 130
-weight: 130 #rem
-aliases: [/static-files]
+ parent: content-management
+ weight: 200
toc: true
+weight: 200
+aliases: [/static-files]
---
By default, the `static/` directory in the site project is used for
@@ -65,6 +65,5 @@ Note 2
: The example above is a [multihost setup][]. In a regular setup, all
the static directories will be available to all sites.
-
[site config]: /getting-started/configuration/#all-configuration-settings
[multihost setup]: /content-management/multilingual/#configure-multilingual-multihost
diff --git a/content/en/content-management/summaries.md b/content/en/content-management/summaries.md
index 3c67a67dc..010e55dcd 100644
--- a/content/en/content-management/summaries.md
+++ b/content/en/content-management/summaries.md
@@ -1,20 +1,16 @@
---
title: Content Summaries
-linktitle: Summaries
+linkTitle: Summaries
description: Hugo generates summaries of your content.
-date: 2017-01-10
-publishdate: 2017-01-10
-lastmod: 2017-01-10
categories: [content management]
keywords: [summaries,abstracts,read more]
menu:
docs:
- parent: "content-management"
- weight: 90
-weight: 90 #rem
-draft: false
-aliases: [/content/summaries/,/content-management/content-summaries/]
+ parent: content-management
+ weight: 160
toc: true
+weight: 160
+aliases: [/content/summaries/,/content-management/content-summaries/]
---
With the use of the `.Summary` [page variable][pagevariables], Hugo generates summaries of content to use as a short version in summary views.
@@ -41,9 +37,9 @@ The Hugo-defined summaries are set to use word count calculated by splitting the
### Manual Summary Splitting
-Alternatively, you may add the <code>&#60;&#33;&#45;&#45;more&#45;&#45;&#62;</code> summary divider where you want to split the article.
+Alternatively, you may add the <code>&#60;&#33;&#45;&#45;more&#45;&#45;&#62;</code> summary divider where you want to split the article.
-For [Org mode content][org], use `# more` where you want to split the article.
+For [Org mode content][org], use `# more` where you want to split the article.
Content that comes before the summary divider will be used as that content's summary and stored in the `.Summary` page variable with all HTML formatting intact.
diff --git a/content/en/content-management/syntax-highlighting.md b/content/en/content-management/syntax-highlighting.md
index 5195b8211..5f8a44ee2 100644
--- a/content/en/content-management/syntax-highlighting.md
+++ b/content/en/content-management/syntax-highlighting.md
@@ -1,22 +1,19 @@
---
title: Syntax Highlighting
+linkTitle: Syntax Highlighting
description: Hugo comes with really fast syntax highlighting from Chroma.
-date: 2017-02-01
-publishdate: 2017-02-01
keywords: [highlighting,chroma,code blocks,syntax]
categories: [content management]
menu:
docs:
- parent: "content-management"
- weight: 300
-weight: 20
-sections_weight: 20
-draft: false
-aliases: [/extras/highlighting/,/extras/highlight/,/tools/syntax-highlighting/]
+ parent: content-management
+ weight: 240
toc: true
+weight: 240
+aliases: [/extras/highlighting/,/extras/highlight/,/tools/syntax-highlighting/]
---
-Hugo uses [Chroma](https://github.com/alecthomas/chroma) as its code highlighter; it is built in Go and is really, really fast -- and for the most important parts compatible with Pygments we used before.
+Hugo uses [Chroma](https://github.com/alecthomas/chroma) as its code highlighter; it is built in Go and is really, really fast.
## Configure Syntax Highlighter
@@ -36,11 +33,11 @@ Run `hugo gen chromastyles -h` for more options. See https://xyproto.github.io/s
## Highlight Shortcode
-Highlighting is carried out via the built-in [`highlight` shortcode](https://gohugo.io/content-management/shortcodes/#highlight). It takes exactly one required parameter for the programming language to be highlighted and requires a closing shortcode. Note that `highlight` is *not* used for client-side javascript highlighting.
+Highlighting is carried out via the built-in [`highlight` shortcode](https://gohugo.io/content-management/shortcodes/#highlight). It takes exactly one required parameter for the programming language to be highlighted and requires a closing shortcode.
Options:
-* `linenos`: configure line numbers. Valid values are `true`, `false`, `table`, or `inline`. `false` will turn off line numbers if it's configured to be on in site config. {{< new-in "0.60.0" >}} `table` will give copy-and-paste friendly code blocks.
+* `linenos`: configure line numbers. Valid values are `true`, `false`, `table`, or `inline`. `false` will turn off line numbers if it's configured to be on in site config. `table` will give copy-and-paste friendly code blocks.
* `hl_lines`: lists a set of line numbers or line number ranges to be highlighted.
* `linenostart=199`: starts the line number count from 199.
* `anchorlinenos`: Configure anchors on line numbers. Valid values are `true` or `false`;
@@ -49,7 +46,7 @@ Options:
### Example: Highlight Shortcode
-```
+```go-html-template
{{</* highlight go "linenos=table,hl_lines=8 15-17,linenostart=199" */>}}
// ... code
{{</* / highlight */>}}
@@ -100,9 +97,9 @@ See [Highlight](/functions/highlight/).
## Highlighting in Code Fences
-Highlighting in code fences is enabled by default.{{< new-in "0.60.0" >}}
+Highlighting in code fences is enabled by default.
-````
+````txt
```go {linenos=table,hl_lines=[8,"15-17"],linenostart=199}
// ... code
```
@@ -134,8 +131,6 @@ func GetTitleFunc(style string) func(s string) string {
}
```
-{{< new-in "0.60.0" >}}Note that only Goldmark supports passing attributes such as `hl_lines`, and it's important that it does not contain any spaces. See [goldmark-highlighting](https://github.com/yuin/goldmark-highlighting) for more information.
-
The options are the same as in the [highlighting shortcode](/content-management/syntax-highlighting/#highlight-shortcode),including `linenos=false`, but note the slightly different Markdown attribute syntax.
## List of Chroma Highlighting Languages
@@ -143,11 +138,3 @@ The options are the same as in the [highlighting shortcode](/content-management/
The full list of Chroma lexers and their aliases (which is the identifier used in the `highlight` template func or when doing highlighting in code fences):
{{< chroma-lexers >}}
-
-[Prism]: https://prismjs.com
-[prismdownload]: https://prismjs.com/download.html
-[Highlight.js]: https://highlightjs.org/
-[Rainbow]: https://craig.is/making/rainbows
-[Syntax Highlighter]: https://alexgorbatchev.com/SyntaxHighlighter/
-[Google Prettify]: https://github.com/google/code-prettify
-[Yandex]: https://yandex.ru/
diff --git a/content/en/content-management/taxonomies.md b/content/en/content-management/taxonomies.md
index 32227d52c..625347203 100644
--- a/content/en/content-management/taxonomies.md
+++ b/content/en/content-management/taxonomies.md
@@ -1,19 +1,16 @@
---
title: Taxonomies
-linktitle:
+linkTitle: Taxonomies
description: Hugo includes support for user-defined taxonomies.
-date: 2017-02-01
-publishdate: 2017-02-01
keywords: [taxonomies,metadata,front matter,terms]
categories: [content management]
menu:
docs:
- parent: "content-management"
- weight: 80
-weight: 80 #rem
-draft: false
-aliases: [/taxonomies/overview/,/taxonomies/usage/,/indexes/overview/,/doc/indexes/,/extras/indexes]
+ parent: content-management
+ weight: 150
toc: true
+weight: 150
+aliases: [/taxonomies/overview/,/taxonomies/usage/,/indexes/overview/,/doc/indexes/,/extras/indexes]
---
## What is a Taxonomy?
@@ -49,7 +46,7 @@ Then, in each of the movies, you would specify terms for each of these taxonomie
To continue with the example of a movie site, the following demonstrates content relationships from the perspective of the taxonomy:
-```
+```txt
Actor <- Taxonomy
Bruce Willis <- Term
The Sixth Sense <- Value
@@ -63,7 +60,7 @@ Actor <- Taxonomy
From the perspective of the content, the relationships would appear differently, although the data and labels used are the same:
-```
+```txt
Unbreakable <- Value
Actors <- Taxonomy
Bruce Willis <- Term
@@ -98,8 +95,6 @@ If you do not want Hugo to create any taxonomies, set `disableKinds` in your [si
disableKinds = ["taxonomy","term"]
{{</ code-toggle >}}
-{{< new-in "0.73.0" >}} We have fixed the before confusing page kinds used for taxonomies (see the listing below) to be in line with the terms used when we talk about taxonomies. We have been careful to avoid site breakage, and you should get an ERROR in the console if you need to adjust your `disableKinds` section.
-
{{% page-kinds %}}
### Default Destinations
@@ -111,7 +106,7 @@ When taxonomies are used---and [taxonomy templates][] are provided---Hugo will a
## Configure Taxonomies
-Custom taxonomies other than the [defaults](#default-taxonomies) must be defined in your [site config][config] before they can be used throughout the site. You need to provide both the plural and singular labels for each taxonomy. For example, `singular key = "plural value"` for TOML and `singular key: "plural value"` for YAML.
+Custom taxonomies other than the [defaults]({{< relref "taxonomies.md#default-taxonomies" >}}) must be defined in your [site config][config] before they can be used throughout the site. You need to provide both the plural and singular labels for each taxonomy. For example, `singular key = "plural value"` for TOML and `singular key: "plural value"` for YAML.
### Example: Adding a custom taxonomy named "series"
@@ -135,7 +130,7 @@ If you want to have just the default `tags` taxonomy, and remove the `categories
tag = "tags"
{{</ code-toggle >}}
-If you want to disable all taxonomies altogether, see the use of `disableKinds` in [Hugo Taxonomy Defaults](#default-taxonomies).
+If you want to disable all taxonomies altogether, see the use of `disableKinds` in [Hugo Taxonomy Defaults]({{< relref "taxonomies.md#default-taxonomies" >}}).
{{% note %}}
You can add content and front matter to your taxonomy list and taxonomy terms pages. See [Content Organization](/content-management/organization/) for more information on how to add an `_index.md` for this purpose.
@@ -174,7 +169,7 @@ project_url = "https://github.com/gohugoio/hugo"
A content file can assign weight for each of its associate taxonomies. Taxonomic weight can be used for sorting or ordering content in [taxonomy list templates][] and is declared in a content file's [front matter][]. The convention for declaring taxonomic weight is `taxonomyname_weight`.
-The following TOML and YAML examples show a piece of content that has a weight of 22, which can be used for ordering purposes when rendering the pages assigned to the "a", "b" and "c" values of the `tags` taxonomy. It has also been assigned the weight of 44 when rendering the "d" category page.
+The following show a piece of content that has a weight of 22, which can be used for ordering purposes when rendering the pages assigned to the "a", "b" and "c" values of the `tags` taxonomy. It has also been assigned the weight of 44 when rendering the "d" category page.
### Example: Taxonomic `weight`
@@ -194,7 +189,7 @@ Currently taxonomies only support the [default `weight => date` ordering of list
## Add custom metadata to a Taxonomy or Term
-If you need to add custom metadata to your taxonomy terms, you will need to create a page for that term at `/content/<TAXONOMY>/<TERM>/_index.md` and add your metadata in it's front matter. Continuing with our 'Actors' example, let's say you want to add a Wikipedia page link to each actor. Your terms pages would be something like this:
+If you need to add custom metadata to your taxonomy terms, you will need to create a page for that term at `/content/<TAXONOMY>/<TERM>/_index.md` and add your metadata in its front matter. Continuing with our 'Actors' example, let's say you want to add a Wikipedia page link to each actor. Your terms pages would be something like this:
{{< code file="/content/actors/bruce-willis/_index.md" >}}
---
diff --git a/content/en/content-management/toc.md b/content/en/content-management/toc.md
index 57228ba50..6cb8e55bf 100644
--- a/content/en/content-management/toc.md
+++ b/content/en/content-management/toc.md
@@ -1,20 +1,16 @@
---
title: Table of Contents
-linktitle:
+linkTitle: Table of Contents
description: Hugo can automatically parse Markdown content and create a Table of Contents you can use in your templates.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [content management]
keywords: [table of contents, toc]
menu:
docs:
- parent: "content-management"
- weight: 130
-weight: 130 #rem
-draft: false
-aliases: [/extras/toc/]
+ parent: content-management
+ weight: 210
toc: true
+weight: 210
+aliases: [/extras/toc/]
---
{{% note "TOC Heading Levels are Fixed" %}}
@@ -27,9 +23,9 @@ Hugo [v0.60.0](https://github.com/gohugoio/hugo/releases/tag/v0.60.0) made a swi
## Usage
-Create your markdown the way you normally would with the appropriate headings. Here is some example content:
+Create your Markdown the way you normally would with the appropriate headings. Here is some example content:
-```
+```md
<!-- Your front matter up here -->
## Introduction
diff --git a/content/en/content-management/types.md b/content/en/content-management/types.md
index da45302a7..8ad0d7f6c 100644
--- a/content/en/content-management/types.md
+++ b/content/en/content-management/types.md
@@ -1,24 +1,21 @@
---
title: Content Types
+linkTitle: Content Types
description: Hugo is built around content organized in sections.
-date: 2017-02-01
categories: [content management]
-keywords: [lists,sections,content types,types,organization]
+keywords: [lists, sections, content types, types, organization]
menu:
docs:
- parent: "content-management"
- weight: 60
-weight: 60 #rem
-draft: false
-aliases: [/content/types]
+ parent: content-management
+ weight: 130
toc: true
+weight: 130
+aliases: [/content/types]
---
A **content type** is a way to organize your content. Hugo resolves the content type from either the `type` in front matter or, if not set, the first directory in the file path. E.g. `content/blog/my-first-event.md` will be of type `blog` if no `type` is set.
A content type is used to
-* Determine how the content is rendered. See [Template Lookup Order](/templates/lookup-order/) and [Content Views](https://gohugo.io/templates/views) for more.
-* Determine which [archetype](/content-management/archetypes/) template to use for new content.
-
-
+- Determine how the content is rendered. See [Template Lookup Order](/templates/lookup-order/) and [Content Views](https://gohugo.io/templates/views) for more.
+- Determine which [archetype](/content-management/archetypes/) template to use for new content.
diff --git a/content/en/content-management/urls.md b/content/en/content-management/urls.md
index 774bd9a58..70ec34ab2 100644
--- a/content/en/content-management/urls.md
+++ b/content/en/content-management/urls.md
@@ -1,20 +1,16 @@
---
title: URL Management
-linktitle: URL Management
+linkTitle: URL Management
description: Hugo supports permalinks, aliases, link canonicalization, and multiple options for handling relative vs absolute URLs.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-03-09
-keywords: [aliases,redirects,permalinks,urls]
categories: [content management]
+keywords: [aliases,redirects,permalinks,urls]
menu:
docs:
- parent: "content-management"
- weight: 110
-weight: 110 #rem
-draft: false
-aliases: [/extras/permalinks/,/extras/aliases/,/extras/urls/,/doc/redirects/,/doc/alias/,/doc/aliases/]
+ parent: content-management
+ weight: 180
toc: true
+weight: 180
+aliases: [/extras/permalinks/,/extras/aliases/,/extras/urls/,/doc/redirects/,/doc/alias/,/doc/aliases/]
---
## Permalinks
@@ -45,7 +41,7 @@ permalinks:
/: /:year/:month/:filename/
{{< /code-toggle >}}
-If the standard date-based permalink configuration does not meet your needs, you can also format URL segments using [Go time formatting directives](https://golang.org/pkg/time/#Time.Format). For example, a URL structure with two digit years and month and day digits without zero padding can be accomplished with:
+If the standard date-based permalink configuration does not meet your needs, you can also format URL segments using [Go time formatting directives](https://pkg.go.dev/time#Time.Format). For example, a URL structure with two digit years and month and day digits without zero padding can be accomplished with:
{{< code-toggle file="config" copy="false" >}}
permalinks:
@@ -83,7 +79,7 @@ The following is a list of values that can be used in a `permalink` definition i
: the content's section
`:sections`
-: the content's sections hierarchy. {{< new-in "0.83.0" >}} Since Hugo 0.83 you can use a selection of the sections using _slice syntax_: `:sections[1:]` includes all but the first, `:sections[:last]` includes all but the last, `:sections[last]` includes only the last, `:sections[1:2]` includes section 2 and 3. Note that this slice access will not throw any out-of-bounds errors, so you don't have to be exact.
+: the content's sections hierarchy. Uou can use a selection of the sections using _slice syntax_: `:sections[1:]` includes all but the first, `:sections[:last]` includes all but the last, `:sections[last]` includes only the last, `:sections[1:2]` includes section 2 and 3. Note that this slice access will not throw any out-of-bounds errors, so you don't have to be exact.
`:title`
: the content's title
@@ -133,7 +129,7 @@ aliases:
---
{{< /code >}}
-Now when you visit any of the locations specified in aliases---i.e., *assuming the same site domain*---you'll be redirected to the page they are specified on. For example, a visitor to `example.com/posts/my-original-url/` will be immediately redirected to `example.com/posts/my-awesome-post/`.
+Now when you visit any of the locations specified in aliases---i.e., _assuming the same site domain_---you'll be redirected to the page they are specified on. For example, a visitor to `example.com/posts/my-original-url/` will be immediately redirected to `example.com/posts/my-awesome-post/`.
### Example: Aliases in Multilingual
@@ -141,14 +137,14 @@ On [multilingual sites][multilingual], each translation of a post can have uniqu
In `/posts/my-new-post.es.md`:
-```
+```md
---
aliases:
- /es/posts/my-original-post/
---
```
-From Hugo 0.55 you can also have page-relative aliases, so ` /es/posts/my-original-post/` can be simplified to the more portable `my-original-post/`
+From Hugo 0.55 you can also have page-relative aliases, so `/es/posts/my-original-post/` can be simplified to the more portable `my-original-post/`
### How Hugo Aliases Work
@@ -156,7 +152,7 @@ When aliases are specified, Hugo creates a directory to match the alias entry. I
For example, a content file at `posts/my-intended-url.md` with the following in the front matter:
-```
+```yml
---
title: My New post
aliases: [/posts/my-old-url/]
@@ -165,7 +161,7 @@ aliases: [/posts/my-old-url/]
Assuming a `baseURL` of `example.com`, the contents of the auto-generated alias `.html` found at `https://example.com/posts/my-old-url/` will contain the following:
-```
+```html
<!DOCTYPE html>
<html>
<head>
@@ -204,7 +200,7 @@ Hugo's default behavior is to render your content with "pretty" URLs. No non-sta
The following demonstrates the concept:
-```
+```txt
content/posts/_index.md
=> example.com/posts/
content/posts/post-1.md
@@ -219,7 +215,7 @@ If you want a specific piece of content to have an exact URL, you can specify th
See [Content Organization][contentorg] for more details on paths.
-```
+```txt
.
└── content
└── about
@@ -236,7 +232,7 @@ See [Content Organization][contentorg] for more details on paths.
Here's the same organization run with `hugo --uglyURLs`:
-```
+```txt
.
└── content
└── about
@@ -251,7 +247,6 @@ Here's the same organization run with `hugo --uglyURLs`:
└── second.md // <- https://example.com/quote/second.html
```
-
## Canonicalization
By default, all relative URLs encountered in the input are left unmodified, e.g. `/css/foo.css` would stay as `/css/foo.css`. The `canonifyURLs` field in your site `config` has a default value of `false`.
@@ -268,13 +263,13 @@ In the May 2014 release of Hugo v0.11, the default value of `canonifyURLs` was s
To find out the current value of `canonifyURLs` for your website, you may use the handy `hugo config` command added in v0.13.
-```
+```txt
hugo config | grep -i canon
```
Or, if you are on Windows and do not have `grep` installed:
-```
+```txt
hugo config | FINDSTR /I canon
```
@@ -300,7 +295,6 @@ url: "custom/foo"
---
```
-
## Relative URLs
By default, all relative URLs are left unchanged by Hugo, which can be problematic when you want to make your site browsable from a local file system.
diff --git a/content/en/contribute/development.md b/content/en/contribute/development.md
index 16489772e..dfdf60ddb 100644
--- a/content/en/contribute/development.md
+++ b/content/en/contribute/development.md
@@ -4,7 +4,6 @@ linktitle: Development
description: Hugo relies heavily on contributions from the open source community.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [contribute]
keywords: [dev,open source]
authors: [digitalcraftsman]
@@ -14,7 +13,6 @@ menu:
weight: 10
weight: 10
sections_weight: 10
-draft: false
toc: true
---
@@ -45,13 +43,13 @@ If you are having trouble following the installation guides for Go, check out [G
Once you're finished installing Go, let's confirm everything is working correctly. Open a terminal---or command line under Windows--and type the following:
-```
+```txt
go version
```
You should see something similar to the following written to the console. Note that the version here reflects the most recent version of Go as of the last update for this page:
-```
+```txt
go version go1.12 darwin/amd64
```
@@ -59,13 +57,13 @@ Next, make sure that you set up your `GOPATH` [as described in the installation
You can print the `GOPATH` with `echo $GOPATH`. You should see a non-empty string containing a valid path to your Go workspace; for example:
-```
+```txt
/Users/<yourusername>/Code/go
```
### Install Go with Homebrew
-If you are a MacOS user and have [Homebrew](https://brew.sh/) installed on your machine, installing Go is as simple as the following command:
+If you are a macOS user and have [Homebrew](https://brew.sh/) installed on your machine, installing Go is as simple as the following command:
{{< code file="install-go.sh" >}}
brew install go
@@ -87,7 +85,7 @@ You will need to have Git installed on your computer to contribute to Hugo devel
Git is a [version control system](https://en.wikipedia.org/wiki/Version_control) to track the changes of source code. Hugo depends on smaller third-party packages that are used to extend the functionality. We use them because we don't want to reinvent the wheel.
-Go ships with a sub-command called `get` that will download these packages for us when we setup our working environment. The source code of the packages is tracked with Git. `get` will interact with the Git servers of the package hosters in order to fetch all dependencies.
+Go ships with a sub-command called `get` that will download these packages for us when we set up our working environment. The source code of the packages is tracked with Git. `get` will interact with the Git servers of the package hosters in order to fetch all dependencies.
Move back to the terminal and check if Git is already installed. Type in `git version` and press enter. You can skip the rest of this section if the command returned a version number. Otherwise [download](https://git-scm.com/downloads) the latest version of Git and follow this [installation guide](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git).
@@ -95,7 +93,7 @@ Finally, check again with `git version` if Git was installed successfully.
### Git Graphical Front Ends
-There are several [GUI clients](https://git-scm.com/downloads/guis) that help you to operate Git. Not all are available for all operating systems and maybe differ in their usage. Because of this we will document how to use the command line, since the commands are the same everywhere.
+There are several [GUI clients](https://git-scm.com/downloads/guis) that help you to operate Git. Not all are available for all operating systems and maybe differ in their usage. Because of this we will document how to use the command-line, since the commands are the same everywhere.
### Install Hub on Your System (Optional)
@@ -103,19 +101,19 @@ Hub is a great tool for working with GitHub. The main site for it is [hub.github
On a Mac, you can install [Hub](https://github.com/github/hub) using [Homebrew](https://brew.sh):
-```
+```txt
brew install hub
```
Now we'll create an [alias in Bash](https://tldp.org/LDP/abs/html/aliases.html) so that typing `git` actually runs `Hub`:
-```
+```txt
echo "alias git='hub'" >> ~/.bash_profile
```
Confirm the installation:
-```
+```txt
git version 2.21.0
hub version 2.10.0
```
@@ -134,26 +132,25 @@ We're going to clone the [master Hugo repository](https://github.com/gohugoio/hu
So, let's make a new directory and clone that master repository:
-```
+```txt
mkdir $HOME/src
cd $HOME/src
git clone https://github.com/gohugoio/hugo.git
```
-> Since Hugo 0.48, Hugo uses the Go Modules support built into Go 1.11 to build.
+> Since Hugo 0.48, Hugo uses the Go Modules support built into Go 1.11 to build.
> The easiest is to clone Hugo in a directory outside of GOPATH
And then, install dependencies of Hugo by running the following in the cloned directory:
-```
+```txt
cd $HOME/src/hugo
go install
```
-
Hugo relies on [mage](https://github.com/magefile/mage) for some convenient build and test targets. If you don't already have it, get it:
-```
+```txt
go install github.com/magefile/mage@latest
```
@@ -169,19 +166,19 @@ Open the [Hugo repository](https://github.com/gohugoio/hugo) on GitHub and click
![Fork button](/images/contribute/development/forking-a-repository.png)
-Now open your fork repository on GitHub and copy the remote url of your fork. You can choose between HTTPS and SSH as protocol that Git should use for the following operations. HTTPS works always [if you're not sure](https://help.github.com/articles/which-remote-url-should-i-use/).
+Now open your fork repository on GitHub and copy the remote URL of your fork. You can choose between HTTPS and SSH as protocol that Git should use for the following operations. HTTPS works always [if you're not sure](https://help.github.com/articles/which-remote-url-should-i-use/).
![Copy remote url](/images/contribute/development/copy-remote-url.png)
Switch back to the terminal and move into the directory of the cloned master repository from the last step.
-```
+```txt
cd $HOME/src/hugo
```
Now Git needs to know that our fork exists by adding the copied remote url:
-```
+```txt
git remote add <YOUR-GITHUB-USERNAME> <COPIED REMOTE-URL>
```
@@ -189,7 +186,7 @@ git remote add <YOUR-GITHUB-USERNAME> <COPIED REMOTE-URL>
Alternatively, you can use the Git wrapper Hub. Hub makes forking a repository easy:
-```
+```txt
git fork
```
@@ -199,13 +196,13 @@ That command will log in to GitHub using your account, create a fork of the repo
Let's check if everything went right by listing all known remotes:
-```
+```txt
git remote -v
```
The output should look similar:
-```
+```txt
digitalcraftsman [email protected]:digitalcraftsman/hugo.git (fetch)
digitalcraftsman [email protected]:digitalcraftsman/hugo.git (push)
origin https://github.com/gohugoio/hugo (fetch)
@@ -220,14 +217,14 @@ You should never develop against the "master" branch. The development team will
First, you should always pull the latest changes from the master repository:
-```
+```txt
git checkout master
git pull
```
Now we can create a new branch for your additions:
-```
+```txt
git checkout -b <BRANCH-NAME>
```
@@ -245,7 +242,7 @@ We have developed a [separate Hugo documentation contribution guide][docscontrib
While making changes in the codebase it's a good idea to build the binary to test them:
-```
+```txt
mage hugo
```
@@ -253,31 +250,33 @@ This command generates the binary file at the root of the repository.
If you want to install the binary in `$GOPATH/bin`, run
-```
+```txt
mage install
```
-### Test
+### Test
+
Sometimes changes on the codebase can cause unintended side effects. Or they don't work as expected. Most functions have their own test cases. You can find them in files ending with `_test.go`.
-Make sure the commands
+Make sure the commands
-```
+```txt
mage -v check
```
passes.
-### Formatting
-The Go code styleguide maybe is opinionated but it ensures that the codebase looks the same, regardless who wrote the code. Go comes with its own formatting tool. Let's apply the styleguide to our additions:
+### Formatting
-```
+The Go code style guide maybe is opinionated but it ensures that the codebase looks the same, regardless who wrote the code. Go comes with its own formatting tool. Let's apply the style guide to our additions:
+
+```txt
mage fmt
```
Once you made your additions commit your changes. Make sure that you follow our [code contribution guidelines](https://github.com/gohugoio/hugo/blob/master/CONTRIBUTING.md):
-```
+```txt
# Add all changed files
git add --all
git commit --message "YOUR COMMIT MESSAGE"
@@ -295,20 +294,20 @@ If you are unsure what a command does leave the commit as it is. We can fix your
Let's say you want to modify the last commit message. Run the following command and replace the current message:
-```
+```txt
git commit --amend -m"YOUR NEW COMMIT MESSAGE"
```
Take a look at the commit log to see the change:
-```
+```txt
git log
# Exit with q
```
-After making the last commit you may have forgot something. There is no need to create a new commit. Just add the latest changes and merge them into the intended commit:
+After making the last commit you may have forgotten something. There is no need to create a new commit. Just add the latest changes and merge them into the intended commit:
-```
+```txt
git add --all
git commit --amend
```
@@ -321,13 +320,13 @@ Modifications such as those described in this section can have serious unintende
This is a bit more advanced. Git allows you to [rebase](https://git-scm.com/docs/git-rebase) commits interactively. In other words: it allows you to rewrite the commit history.
-```
+```txt
git rebase --interactive @~6
```
The `6` at the end of the command represents the number of commits that should be modified. An editor should open and present a list of last six commit messages:
-```
+```txt
pick 80d02a1 tpl: Add hasPrefix to the template funcs' "smoke test"
pick aaee038 tpl: Sort the smoke tests
pick f0dbf2c tpl: Add the other test case for hasPrefix
@@ -340,7 +339,7 @@ In the case above we should merge the last two commits in the commit of this tut
All operations are written before the commit message. Replace "pick" with an operation. In this case `squash` or `s` for short:
-```
+```txt
pick 80d02a1 tpl: Add hasPrefix to the template funcs' "smoke test"
pick aaee038 tpl: Sort the smoke tests
pick f0dbf2c tpl: Add the other test case for hasPrefix
@@ -353,7 +352,7 @@ We also want to rewrite the commits message of the third last commit. We forgot
You should end up with a similar setup:
-```
+```txt
pick 80d02a1 tpl: Add hasPrefix to the template funcs' "smoke test"
pick aaee038 tpl: Sort the smoke tests
pick f0dbf2c tpl: Add the other test case for hasPrefix
@@ -366,7 +365,7 @@ Close the editor. It should open again with a new tab. A text is instructing you
A last time a new tab opens. Enter a new commit message and save again. Your terminal should contain a status message. Hopefully this one:
-```
+```txt
Successfully rebased and updated refs/heads/<BRANCHNAME>.
```
@@ -374,9 +373,9 @@ Check the commit log if everything looks as expected. Should an error occur you
### Push commits
-To push our commits to the fork on GitHub we need to specify a destination. A destination is defined by the remote and a branch name. Earlier, the defined that the remote url of our fork is the same as our GitHub handle, in my case `digitalcraftsman`. The branch should have the same as our local one. This makes it easy to identify corresponding branches.
+To push our commits to the fork on GitHub we need to specify a destination. A destination is defined by the remote and a branch name. Earlier, the defined that the remote URL of our fork is the same as our GitHub handle, in my case `digitalcraftsman`. The branch should have the same as our local one. This makes it easy to identify corresponding branches.
-```
+```txt
git push --set-upstream <YOUR-GITHUB-USERNAME> <BRANCHNAME>
```
@@ -402,7 +401,7 @@ Last but not least you should accept the contributor license agreement (CLA). A
### Automatic builds
-We use a GitHub Actions workflow to build and test. This is a matrix build across combinations of operating system (masOS, Windows, and Ubuntu) and Go versions. The workflow is triggered by the submission of a pull request. If you are a first-time contributor, the workflow requires approval from a project maintainer.
+We use a GitHub Actions workflow to build and test. This is a matrix build across combinations of operating system (macOS, Windows, and Ubuntu) and Go versions. The workflow is triggered by the submission of a pull request. If you are a first-time contributor, the workflow requires approval from a project maintainer.
## Where to start?
@@ -417,18 +416,17 @@ Feel free to [open an issue][newissue] if you think you found a bug or you have
* [The Git Book][gitbook] (Free)
* [Go Bootcamp][gobootcamp]
-
[codecademy]: https://www.codecademy.com/learn/learn-git
[contributors]: https://github.com/gohugoio/hugo/graphs/contributors
[docscontrib]: /contribute/documentation/
[forums]: https://discourse.gohugo.io
[gitbook]: https://git-scm.com/
[gobootcamp]: https://www.golangbootcamp.com/book/get_setup
-[godl]: https://golang.org/dl/
-[goinstall]: https://golang.org/doc/install
+[godl]: https://go.dev/dl/
+[goinstall]: https://go.dev/doc/install
[gvm]: https://github.com/moovweb/gvm
[issues]: https://github.com/gohugoio/hugo/issues
[newissue]: https://github.com/gohugoio/hugo/issues/new
[releases]: /getting-started/
-[setupgopath]: https://golang.org/doc/code.html#Workspaces
+[setupgopath]: https://go.dev/doc/code#Workspaces
[trygit]: https://try.github.io/levels/1/challenges/1
diff --git a/content/en/contribute/documentation.md b/content/en/contribute/documentation.md
index df937f1e1..939387384 100644
--- a/content/en/contribute/documentation.md
+++ b/content/en/contribute/documentation.md
@@ -4,7 +4,6 @@ linktitle: Documentation
description: Documentation is an integral part of any open source project. The Hugo docs are as much a work in progress as the source it attempts to cover.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [contribute]
keywords: [docs,documentation,community, contribute]
menu:
@@ -13,7 +12,6 @@ menu:
weight: 20
weight: 20
sections_weight: 20
-draft: false
aliases: [/contribute/docs/]
toc: true
---
@@ -24,7 +22,7 @@ It's best to make changes to the Hugo docs on your local machine to check for co
You can then create a separate branch for your additions. Be sure to choose a descriptive branch name that best fits the type of content. The following is an example of a branch name you might use for adding a new website to the showcase:
-```
+```txt
git checkout -b jon-doe-showcase-addition
```
@@ -34,15 +32,15 @@ The Hugo docs make heavy use of Hugo's [archetypes][] feature. All content secti
Adding new content to the Hugo docs follows the same pattern, regardless of the content section:
-```
+```txt
hugo new <DOCS-SECTION>/<new-content-lowercase>.md
```
### Add a New Function
-Once you have cloned the Hugo repository, you can create a new function via the following command. Keep the file name lowercase.
+Once you have cloned the Hugo repository, you can create a new function via the following command. Keep the filename lowercase.
-```
+```txt
hugo new functions/newfunction.md
```
@@ -94,13 +92,13 @@ Code blocks are crucial for providing examples of Hugo's new features to end use
### Standard Syntax
-Across many pages on the Hugo docs, the typical triple-back-tick markdown syntax (```` ``` ````) is used. If you do not want to take the extra time to implement the following code block shortcodes, please use standard GitHub-flavored markdown. The Hugo docs use a version of [highlight.js](https://highlightjs.org/) with a specific set of languages.
+Across many pages on the Hugo docs, the typical triple-back-tick Markdown syntax (```` ``` ````) is used. If you do not want to take the extra time to implement the following code block shortcodes, please use standard GitHub-flavored Markdown.
-Your options for languages are `xml`/`html`, `go`/`golang`, `md`/`markdown`/`mkd`, `handlebars`, `apache`, `toml`, `yaml`, `json`, `css`, `asciidoc`, `ruby`, `powershell`/`ps`, `scss`, `sh`/`zsh`/`bash`/`git`, `http`/`https`, and `javascript`/`js`.
-
-````
-```
-<h1>Hello world!</h1>
+````txt
+```go-html-template
+{{ range site.RegularPages }}
+ <h2><a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a></h2>
+{{ end }}
```
````
@@ -117,7 +115,7 @@ With the `code` shortcodes, *you must include triple back ticks and a language d
`code` is the Hugo docs shortcode you'll use most often. `code` requires has only one named parameter: `file`. Here is the pattern:
-```
+```go-html-template
{{%/* code file="smart/file/name/with/path.html" download="download.html" copy="true" */%}}
A whole bunch of coding going on up in here!
{{%/* /code */%}}
@@ -125,7 +123,6 @@ A whole bunch of coding going on up in here!
The following are the arguments passed into `code`:
-
***`file`***
: the only *required* argument. `file` is needed for styling but also plays an important role in helping users create a mental model around Hugo's directory structure. Visually, this will be displayed as text in the top left of the code block.
@@ -142,7 +139,7 @@ This example HTML code block tells Hugo users the following:
1. This file *could* live in `layouts/_default`, as demonstrated by `layouts/_default/single.html` as the value for `file`.
2. This snippet is complete enough to be downloaded and implemented in a Hugo project, as demonstrated by `download="single.html"`.
-```
+```go-html-template
{{</* code file="layouts/_default/single.html" download="single.html" */>}}
{{ define "main" }}
<main>
@@ -210,7 +207,7 @@ The preceding `output` example will render as follows to the Hugo docs:
Blockquotes can be added to the Hugo documentation using [typical Markdown blockquote syntax][bqsyntax]:
-```
+```md
> Without the threat of punishment, there is no joy in flight.
```
@@ -220,7 +217,7 @@ The preceding blockquote will render as follows in the Hugo docs:
However, you can add a quick and easy `<cite>` element (added on the client via JavaScript) by separating your main blockquote and the citation with a hyphen with a single space on each side:
-```
+```md
> Without the threat of punishment, there is no joy in flight. - [Kobo Abe](https://en.wikipedia.org/wiki/Kobo_Abe)
```
diff --git a/content/en/contribute/themes.md b/content/en/contribute/themes.md
index 403bac825..c515d1fcf 100644
--- a/content/en/contribute/themes.md
+++ b/content/en/contribute/themes.md
@@ -4,7 +4,6 @@ linktitle: Themes
description: If you've built a Hugo theme and want to contribute back to the Hugo Community, share it with us.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-27
categories: [contribute]
keywords: [contribute,themes,design]
authors: [digitalcraftsman]
@@ -14,7 +13,6 @@ menu:
weight: 30
weight: 30
sections_weight: 30
-draft: false
aliases: [/contribute/theme/]
wip: true
toc: true
diff --git a/content/en/functions/GetPage.md b/content/en/functions/GetPage.md
index aa5e9323f..0c74e628b 100644
--- a/content/en/functions/GetPage.md
+++ b/content/en/functions/GetPage.md
@@ -46,7 +46,7 @@ And since `Page` also provides a `.GetPage` method, the above is the same as:
## .GetPage and Multilingual Sites
-The previous examples have used the full content filename to lookup the post. Depending on how you have organized your content (whether you have the language code in the file name or not, e.g. `my-post.en.md`), you may want to do the lookup without extension. This will get you the current language's version of the page:
+The previous examples have used the full content filename to look up the post. Depending on how you have organized your content (whether you have the language code in the file name or not, e.g. `my-post.en.md`), you may want to do the lookup without extension. This will get you the current language's version of the page:
```go-html-template
{{ with .Site.GetPage "/blog/my-post" }}{{ .Title }}{{ end }}
diff --git a/content/en/functions/RenderString.md b/content/en/functions/RenderString.md
index e414b11ca..e4440971f 100644
--- a/content/en/functions/RenderString.md
+++ b/content/en/functions/RenderString.md
@@ -10,8 +10,6 @@ keywords: [markdown,goldmark,render]
signature: [".RenderString MARKUP"]
---
-{{< new-in "0.62.0" >}}
-
`.RenderString` is a method on `Page` that renders some markup to HTML using the content renderer defined for that page (if not set in the options).
The method takes an optional map argument with these options:
@@ -32,5 +30,4 @@ Some examples:
{{ "/italic org mode/" | $p.RenderString $optOrg }}
```
-
-**Note** that this method is more powerful than the similar [markdownify](/functions/markdownify/) function as it also supports [Render Hooks](/getting-started/configuration-markup/#markdown-render-hooks) and it has options to render other markup formats.
+{{< new-in "0.93.0" >}} **Note**: [markdownify](/functions/markdownify/) uses this function in order to support [Render Hooks](/getting-started/configuration-markup/#markdown-render-hooks).
diff --git a/content/en/functions/abslangurl.md b/content/en/functions/abslangurl.md
index d9818fcaf..11d540bde 100644
--- a/content/en/functions/abslangurl.md
+++ b/content/en/functions/abslangurl.md
@@ -1,27 +1,61 @@
---
title: absLangURL
-description: Adds the absolute URL with correct language prefix according to site configuration for multilingual.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
+description: Returns an absolute URL with a language prefix, if any.
categories: [functions]
menu:
docs:
- parent: "functions"
-keywords: [multilingual,i18n,urls]
+ parent: functions
+keywords: [urls, multilingual,i18n]
signature: ["absLangURL INPUT"]
-workson: []
-hugoversion:
-relatedfuncs: [relLangURL]
-deprecated: false
-aliases: []
---
-Both `absLangURL` and [`relLangURL`](/functions/rellangurl/) are similar to their [`absURL`](/functions/absurl/) and [`relURL`](/functions/relurl) relatives but will add the correct language prefix when the site is configured with more than one language.
+Use this function with both monolingual and multilingual configurations. The URL returned by this function depends on:
-So for a site `baseURL` set to `https://example.com/hugo/` and the current language is `en`:
+- Whether the input begins with a slash
+- The `baseURL` in site configuration
+- The language prefix, if any
+In examples that follow, the project is multilingual with content in both Español (`es`) and English (`en`). The default language is Español. The returned values are from the English site.
+
+### Input does not begin with a slash
+
+If the input does not begin with a slash, the resulting URL will be correct regardless of the `baseURL`.
+
+With `baseURL = https://example.org/`
+
+```go-html-template
+{{ absLangURL "" }} → https://example.org/en/
+{{ absLangURL "articles" }} → https://example.org/en/articles
+{{ absLangURL "style.css" }} → https://example.org/en/style.css
+```
+
+With `baseURL = https://example.org/docs/`
+
+```go-html-template
+{{ absLangURL "" }} → https://example.org/docs/en/
+{{ absLangURL "articles" }} → https://example.org/docs/en/articles
+{{ absLangURL "style.css" }} → https://example.org/docs/en/style.css
```
-{{ "blog/" | absLangURL }} → "https://example.com/hugo/en/blog/"
-{{ "blog/" | relLangURL }} → "/hugo/en/blog/"
+
+### Input begins with a slash
+
+If the input begins with a slash, the resulting URL will be incorrect when the `baseURL` includes a subdirectory. With a leading slash, the function returns a URL relative to the protocol+host section of the `baseURL`.
+
+With `baseURL = https://example.org/`
+
+```go-html-template
+{{ absLangURL "/" }} → https://example.org/en/
+{{ absLangURL "/articles" }} → https://example.org/en/articles
+{{ absLangURL "/style.css" }} → https://example.org/en/style.css
```
+
+With `baseURL = https://example.org/docs/`
+
+```go-html-template
+{{ absLangURL "/" }} → https://example.org/en/
+{{ absLangURL "/articles" }} → https://example.org/en/articles
+{{ absLangURL "/style.css" }} → https://example.org/en/style.css
+
+{{% note %}}
+The last three examples are not desirable in most situations. As a best practice, never include a leading slash when using this function.
+{{% /note %}}
diff --git a/content/en/functions/absurl.md b/content/en/functions/absurl.md
index 13524d2d6..efea2df75 100644
--- a/content/en/functions/absurl.md
+++ b/content/en/functions/absurl.md
@@ -1,50 +1,61 @@
---
title: absURL
-description: Creates an absolute URL based on the configured baseURL.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
+description: Returns an absolute URL.
categories: [functions]
menu:
docs:
- parent: "functions"
+ parent: functions
keywords: [urls]
signature: ["absURL INPUT"]
-workson: []
-hugoversion:
-relatedfuncs: [relURL]
-deprecated: false
-aliases: []
---
-Both `absURL` and `relURL` consider the configured value of `baseURL` in your site's [`config` file][configuration]. Given a `baseURL` set to `https://example.com/hugo/`:
+With multilingual configurations, use the [`absLangURL`] function instead. The URL returned by this function depends on:
+- Whether the input begins with a slash
+- The `baseURL` in site configuration
+
+### Input does not begin with a slash
+
+If the input does not begin with a slash, the resulting URL will be correct regardless of the `baseURL`.
+
+With `baseURL = https://example.org/`
+
+```go-html-template
+{{ absURL "" }} → https://example.org/
+{{ absURL "articles" }} → https://example.org/articles
+{{ absURL "style.css" }} → https://example.org/style.css
```
-{{ "mystyle.css" | absURL }} → "https://example.com/hugo/mystyle.css"
-{{ "mystyle.css" | relURL }} → "/hugo/mystyle.css"
-{{ "http://gohugo.io/" | relURL }} → "http://gohugo.io/"
-{{ "http://gohugo.io/" | absURL }} → "http://gohugo.io/"
+
+With `baseURL = https://example.org/docs/`
+
+```go-html-template
+{{ absURL "" }} → https://example.org/docs/
+{{ absURL "articles" }} → https://example.org/docs/articles
+{{ absURL "style.css" }} → https://example.org/docs/style.css
```
-The last two examples may look strange but can be very useful. For example, the following shows how to use `absURL` in [JSON-LD structured data (SEO)][jsonld], where some of your images for a piece of content may or may not be hosted locally:
+### Input begins with a slash
-{{< code file="layouts/partials/schemaorg-metadata.html" download="schemaorg-metadata.html" >}}
-<script type="application/ld+json">
-{
- "@context" : "http://schema.org",
- "@type" : "BlogPosting",
- "image" : {{ apply .Params.images "absURL" "." }}
-}
-</script>
-{{< /code >}}
+If the input begins with a slash, the resulting URL will be incorrect when the `baseURL` includes a subdirectory. With a leading slash, the function returns a URL relative to the protocol+host section of the `baseURL`.
-The above uses the [apply function][] and also exposes how the Go template parser JSON-encodes objects inside `<script>` tags. See [the safeJS template function][safejs] for examples of how to tell Hugo not to escape strings inside of such tags.
+With `baseURL = https://example.org/`
+
+```go-html-template
+{{ absURL "/" }} → https://example.org/
+{{ absURL "/articles" }} → https://example.org/articles
+{{ absURL "/style.css" }} → https://example.org/style.css
+```
+
+With `baseURL = https://example.org/docs/`
+
+```go-html-template
+{{ absURL "/" }} → https://example.org/
+{{ absURL "/articles" }} → https://example.org/articles
+{{ absURL "/style.css" }} → https://example.org/style.css
+```
-{{% note "Ending Slash" %}}
-`absURL` and `relURL` are smart about missing slashes, but they will *not* add a closing slash to a URL if it is not present.
+{{% note %}}
+The last three examples are not desirable in most situations. As a best practice, never include a leading slash when using this function.
{{% /note %}}
-[apply function]: /functions/apply/
-[configuration]: /getting-started/configuration/
-[jsonld]: https://developers.google.com/search/docs/guides/intro-structured-data
-[safejs]: /functions/safejs
+[`absLangURL`]: /functions/abslangurl/
diff --git a/content/en/functions/complement.md b/content/en/functions/complement.md
index a41faf524..91640d803 100644
--- a/content/en/functions/complement.md
+++ b/content/en/functions/complement.md
@@ -1,29 +1,80 @@
---
-title: "complement"
-description: "`collections.Complement` (alias `complement`) gives the elements of a collection that are not in any of the others."
-date: 2018-11-07
+title: complement
+description: Returns the elements of the last collection that are not in any of the others.
categories: [functions]
menu:
docs:
- parent: "functions"
-keywords: [collections,intersect,union]
-signature: ["COLLECTION | complement COLLECTION [COLLECTION]..." ]
-hugoversion: "0.51"
+ parent: functions
+keywords: [collections]
+signature:
+- "complement COLLECTION [COLLECTION]..."
+- "collections.Complement COLLECTION [COLLECTION]..."
+relatedfuncs: [intersect,symdiff,union]
aliases: []
---
-Example:
+To find the elements within `$c3` that do not exist in `$c1` or `$c2`:
```go-html-template
-{{ $pages := site.RegularPages | first 50 }}
-{{ $news := where $pages "Type" "news" | first 5 }}
-{{ $blog := where $pages "Type" "blog" | first 5 }}
-{{ $other := $pages | complement $news $blog | first 10 }}
+{{ $c1 := slice 3 }}
+{{ $c2 := slice 4 5 }}
+{{ $c3 := slice 1 2 3 4 5 }}
+
+{{ complement $c1 $c2 $c3 }} → [1 2]
+```
+
+{{% note %}}
+Make your code simpler to understand by using a [chained pipeline]:
+
+[chained pipeline]: https://pkg.go.dev/text/template#hdr-Pipelines
+{{% /note %}}
+
+
+```go-html-template
+{{ $c3 | complement $c1 $c2 }} → [1 2]
```
-The above is an imaginary use case for the home page where you want to display different page listings in sections/boxes on different places on the page: 5 from `news`, 5 from the `blog` and then 10 of the pages not shown in the other listings, to _complement_ them.
+You can also use the `complement` function with page collections. Let's say your site has five content types:
+```text
+content/
+├── blog/
+├── books/
+├── faqs/
+├── films/
+└── songs/
+```
+To list everything except blog articles (`blog`) and frequently asked questions (`faqs`):
+```go-html-template
+{{ $blog := where site.RegularPages "Type" "blog" }}
+{{ $faqs := where site.RegularPages "Type" "faqs" }}
+{{ range site.RegularPages | complement $blog $faqs }}
+ <a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a>
+{{ end }}
+```
+{{% note %}}
+Although the example above demonstrates the `complement` function, you could use the [`where`] function as well:
+
+[`where`]: /functions/where/
+{{% /note %}}
+
+```go-html-template
+{{ range where site.RegularPages "Type" "not in" (slice "blog" "faqs") }}
+ <a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a>
+{{ end }}
+```
+
+In this example we use the `complement` function to remove [stop words] from a sentence:
+
+```go-html-template
+{{ $text := "The quick brown fox jumps over the lazy dog" }}
+{{ $stopWords := slice "a" "an" "in" "over" "the" "under" }}
+{{ $filtered := split $text " " | complement $stopWords }}
+
+{{ delimit $filtered " " }} → The quick brown fox jumps lazy dog
+```
+[stop words]: https://en.wikipedia.org/wiki/Stop_word
diff --git a/content/en/functions/dateformat.md b/content/en/functions/dateformat.md
index 362efabd3..7a16e80b2 100644
--- a/content/en/functions/dateformat.md
+++ b/content/en/functions/dateformat.md
@@ -22,7 +22,7 @@ deprecated: false
{{ time.Format "Monday, Jan 2, 2006" "2015-01-21" }} → "Wednesday, Jan 21, 2015"
```
-Note that since Hugo 0.87.0, `time.Format` will return a localized string for the current language. {{< new-in "0.87.0" >}}
+`time.Format` returns a localized string for the current language.
The `LAYOUT` string can be either:
@@ -34,9 +34,7 @@ See the [`time` function](/functions/time/) to convert a timestamp string to a G
## Date/time formatting layouts
-{{< new-in "0.87.0" >}}
-
-Go's date layout strings can be hard to reason about, especially with multiple languages. Since Hugo 0.87.0 you can alternatively use some predefined layout identifiers that will output localized dates or times:
+Go's date layout strings can be hard to reason about, especially with multiple languages. You can alternatively use some predefined layout identifiers that will output localized dates or times:
```go-html-template
{{ .Date | time.Format ":date_long" }}
diff --git a/content/en/functions/dict.md b/content/en/functions/dict.md
index 966b6af3e..5c8ad9d8a 100644
--- a/content/en/functions/dict.md
+++ b/content/en/functions/dict.md
@@ -3,7 +3,6 @@ title: dict
description: Creates a dictionary from a list of key and value pairs.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-26
categories: [functions]
menu:
docs:
@@ -25,21 +24,20 @@ Note that the `key` can be either a `string` or a `string slice`. The latter is
{{ $m := dict (slice "a" "b" "c") "value" }}
```
-
## Example: Using `dict` to pass multiple values to a `partial`
-The partial below creates a SVG and expects `fill`, `height` and `width` from the caller:
+The partial below creates an SVG and expects `fill`, `height` and `width` from the caller:
-**Partial definition**
+### Partial definition
{{< code file="layouts/partials/svgs/external-links.svg" download="external-links.svg" >}}
-<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
+<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
fill="{{ .fill }}" width="{{ .width }}" height="{{ .height }}" viewBox="0 0 32 32" aria-label="External Link">
<path d="M25.152 16.576v5.696q0 2.144-1.504 3.648t-3.648 1.504h-14.848q-2.144 0-3.648-1.504t-1.504-3.648v-14.848q0-2.112 1.504-3.616t3.648-1.536h12.576q0.224 0 0.384 0.16t0.16 0.416v1.152q0 0.256-0.16 0.416t-0.384 0.16h-12.576q-1.184 0-2.016 0.832t-0.864 2.016v14.848q0 1.184 0.864 2.016t2.016 0.864h14.848q1.184 0 2.016-0.864t0.832-2.016v-5.696q0-0.256 0.16-0.416t0.416-0.16h1.152q0.256 0 0.416 0.16t0.16 0.416zM32 1.152v9.12q0 0.48-0.352 0.8t-0.8 0.352-0.8-0.352l-3.136-3.136-11.648 11.648q-0.16 0.192-0.416 0.192t-0.384-0.192l-2.048-2.048q-0.192-0.16-0.192-0.384t0.192-0.416l11.648-11.648-3.136-3.136q-0.352-0.352-0.352-0.8t0.352-0.8 0.8-0.352h9.12q0.48 0 0.8 0.352t0.352 0.8z"></path>
</svg>
{{< /code >}}
-**Partial call**
+### Partial call
The `fill`, `height` and `width` values can be stored in one object with `dict` and passed to the partial:
@@ -47,6 +45,4 @@ The `fill`, `height` and `width` values can be stored in one object with `dict`
{{ partial "svgs/external-links.svg" (dict "fill" "#01589B" "width" 10 "height" 20 ) }}
{{< /code >}}
-
-
[partials]: /templates/partials/
diff --git a/content/en/functions/errorf.md b/content/en/functions/errorf.md
index 41ea2f192..04fd0edb0 100644
--- a/content/en/functions/errorf.md
+++ b/content/en/functions/errorf.md
@@ -30,7 +30,7 @@ Both functions return an empty string, so the messages are only printed to the c
{{ warnf "You should update the shortcodes in %q" .Path }}
```
-Note that `errorf`, `erroridf`, and `warnf` support all the formatting verbs of the [fmt](https://golang.org/pkg/fmt/) package.
+Note that `errorf`, `erroridf`, and `warnf` support all the formatting verbs of the [fmt](https://pkg.go.dev/fmt) package.
## Suppress errors
diff --git a/content/en/functions/findRe.md b/content/en/functions/findRe.md
index b6375be9c..2896e3cd1 100644
--- a/content/en/functions/findRe.md
+++ b/content/en/functions/findRe.md
@@ -1,44 +1,40 @@
---
title: findRE
-description: Returns a list of strings that match the regular expression.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
+description: Returns a slice of strings that match the regular expression.
categories: [functions]
menu:
docs:
- parent: "functions"
+ parent: functions
keywords: [regex]
-signature: ["findRE PATTERN INPUT [LIMIT]"]
-workson: []
-hugoversion:
-relatedfuncs: []
-deprecated: false
+signature:
+ - "findRE PATTERN INPUT [LIMIT]"
+ - "strings.FindRE PATTERN INPUT [LIMIT]"
+relatedfuncs: [replaceRE]
aliases: []
---
+By default, the `findRE` function finds all matches. You can limit the number of matches with an optional LIMIT paramater.
-By default all matches will be included. The number of matches can be limited with an optional third parameter.
+When specifying the regular expression, use a raw [string literal] (backticks) instead of an interpreted string literal (double quotes) to simplify the syntax. With an interpreted string literal you must escape backslashes.
-The example below returns a list of all second level headers (`<h2>`) in the content:
+The syntax of the regular expression is the same general syntax used by Perl, Python, and other languages. More precisely, it is the syntax accepted by [RE2] except for `\C`.
-```
-{{ findRE "<h2.*?>(.|\n)*?</h2>" .Content }}
+This example returns a slice of all second level headings (`h2` elements) within the rendered `.Content`:
+
+```go-html-template
+{{ findRE `(?s)<h2.*?>.*?</h2>` .Content }}
```
-You can limit the number of matches in the list with a third parameter. The following example shows how to limit the returned value to just one match (or none, if there are no matched substrings):
+The `s` flag causes `.` to match `\n` as well, allowing us to find an `h2` element that contains newlines.
-```
-{{ findRE "<h2.*?>(.|\n)*?</h2>" .Content 1 }}
- <!-- returns ["<h2 id="#foo">Foo</h2>"] -->
+To limit the number of matches to one:
+
+```go-html-template
+{{ findRE `(?s)<h2.*?>.*?</h2>` .Content 1 }}
```
{{% note %}}
-Hugo uses Go's [Regular Expression package](https://golang.org/pkg/regexp/), which is the same general syntax used by Perl, Python, and other languages but with a few minor differences for those coming from a background in PCRE. For a full syntax listing, see the [GitHub wiki for re2](https://github.com/google/re2/wiki/Syntax).
-
-If you are just learning RegEx, or at least Go's flavor, you can practice pattern matching in the browser at <https://regex101.com/>.
+You can write and test your regular expression using [regex101.com](https://regex101.com/). Be sure to select the Go flavor before you begin.
{{% /note %}}
-[partials]: /templates/partials/
-[`plainify`]: /functions/plainify/
-[toc]: /content-management/toc/
-[`urlize`]: /functions/urlize
+[RE2]: https://github.com/google/re2/wiki/Syntax
+[string literal]: https://go.dev/ref/spec#String_literals
diff --git a/content/en/functions/format.md b/content/en/functions/format.md
index 199030782..4ef806f45 100644
--- a/content/en/functions/format.md
+++ b/content/en/functions/format.md
@@ -93,7 +93,7 @@ More examples can be found in Go's [documentation for the time package][timecons
### Cardinal Numbers and Ordinal Abbreviations
-Spelled-out cardinal numbers (e.g. "one", "two", and "three") are not currently supported.
+Spelled-out cardinal numbers (e.g. "one", "two", and "three") are not currently supported.
Ordinal abbreviations (i.e., with shorted suffixes like "1st", "2nd", and "3rd") are not currently directly supported. By using `{{.Date.Format "Jan 2nd 2006"}}`, Hugo assumes you want to append `nd` as a string to the day of the month. However, you can chain functions together to create something like this:
diff --git a/content/en/functions/get.md b/content/en/functions/get.md
index c5b75c7fd..27f348807 100644
--- a/content/en/functions/get.md
+++ b/content/en/functions/get.md
@@ -18,12 +18,11 @@ aliases: []
needsexample: true
---
-
`.Get` is specifically used when creating your own [shortcode template][sc], to access the [positional and named](/templates/shortcode-templates/#positional-vs-named-parameters) parameters passed to it. When used with a numeric INDEX, it queries positional parameters (starting with 0). With a string KEY, it queries named parameters.
-When accessing a named parameter that does not exist, `.Get` returns an empty string instead of interrupting the build. The same goes with positional parameters in hugo version 0.40 and after. This allows you to chain `.Get` with `if`, `with`, `default` or `cond` to check for parameter existence. For example, you may now use:
+When accessing named or positional parameters that do not exist, `.Get` returns an empty string instead of interrupting the build. This allows you to chain `.Get` with `if`, `with`, `default` or `cond` to check for parameter existence. For example:
-```
+```go-html-template
{{ $quality := default "100" (.Get 1) }}
```
diff --git a/content/en/functions/getenv.md b/content/en/functions/getenv.md
index f7f71d35c..93e93a382 100644
--- a/content/en/functions/getenv.md
+++ b/content/en/functions/getenv.md
@@ -41,3 +41,6 @@ And then retrieve the values within a template:
{{ os.Getenv "MY_VAR1" }} --> foo
{{ os.Getenv "MY_VAR2" }} --> bar
```
+
+With Hugo v0.91.0 and later, you must explicitly allow access to environment variables. For details, review [Hugo's Security Policy](/about/security-model/#security-policy). By default, environment variables beginning with `HUGO_` are allowed when using the `os.Getenv` function.
+
diff --git a/content/en/functions/haschildren.md b/content/en/functions/haschildren.md
deleted file mode 100644
index 1deeb7277..000000000
--- a/content/en/functions/haschildren.md
+++ /dev/null
@@ -1,22 +0,0 @@
----
-title: .HasChildren
-description:
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
-categories: [functions]
-menu:
- docs:
- parent: "functions"
-keywords: [menus]
-toc:
-signature: ["HasChildren"]
-workson: [menus]
-hugoversion:
-relatedfuncs: []
-deprecated: false
-draft: true
-aliases: []
----
-
-Used in [menu templates](/templates/menu-templates/).
diff --git a/content/en/functions/hasmenucurrent.md b/content/en/functions/hasmenucurrent.md
index dbd4aa418..fea980120 100644
--- a/content/en/functions/hasmenucurrent.md
+++ b/content/en/functions/hasmenucurrent.md
@@ -23,6 +23,6 @@ aliases: []
returns `true` if the PAGE is the same object as the `.Page` in one of the
**children menu entries** under MENUENTRY in a given MENU.
-{{< new-in "0.86.0" >}} If MENUENTRY's `.Page` is a [section](/content-management/sections/) then, from Hugo `0.86.0`, this method also returns true for any descendant of that section..
+If MENUENTRY's `.Page` is a [section](/content-management/sections/) then, from Hugo `0.86.0`, this method also returns true for any descendant of that section..
You can find its example use in [menu templates](/templates/menu-templates/).
diff --git a/content/en/functions/highlight.md b/content/en/functions/highlight.md
index 40f3a78de..8324edb81 100644
--- a/content/en/functions/highlight.md
+++ b/content/en/functions/highlight.md
@@ -77,10 +77,10 @@ If the `LANG` parameter is blank or an unrecognized language, auto-detect the la
{{% note %}}
Instead of specifying both `lineNos` and `lineNumbersInTable`, you can use the following shorthand notation:
-`lineNos=inline`
+`lineNos=inline`
: equivalent to `lineNos=true` and `lineNumbersInTable=false`
-`lineNos=table`
+`lineNos=table`
: equivalent to `lineNos=true` and `lineNumbersInTable=true`
{{% /note %}}
diff --git a/content/en/functions/hugo.md b/content/en/functions/hugo.md
index 1792f5a8d..7c0f23629 100644
--- a/content/en/functions/hugo.md
+++ b/content/en/functions/hugo.md
@@ -22,10 +22,10 @@ aliases: []
`hugo` returns an instance that contains the following functions:
hugo.Generator
-: `<meta>` tag for the version of Hugo that generated the site. `hugo.Generator` outputs a *complete* HTML tag; e.g. `<meta name="generator" content="Hugo 0.63.2" />`
+: `<meta>` tag for the version of Hugo that generated the site. `hugo.Generator` outputs a *complete* HTML tag; e.g. `<meta name="generator" content="Hugo 0.99.1" />`
hugo.Version
-: the current version of the Hugo binary you are using e.g. `0.63.2`
+: the current version of the Hugo binary you are using e.g. `0.99.1`
hugo.GoVersion
: returns the version of Go that the Hugo binary was built with. {{< new-in "0.101.0" >}}
@@ -39,7 +39,7 @@ hugo.CommitHash
hugo.BuildDate
: the compile date of the current Hugo binary formatted with RFC 3339 e.g. `2002-10-02T10:00:00-05:00`
-hugo.IsExtended {{< new-in "0.83.0" >}}
+hugo.IsExtended
: whether this is the extended Hugo binary.
hugo.IsProduction
diff --git a/content/en/functions/images/index.md b/content/en/functions/images/index.md
index 7dd5843ee..0cf45b6ee 100644
--- a/content/en/functions/images/index.md
+++ b/content/en/functions/images/index.md
@@ -15,8 +15,6 @@ See [images.Filter](#filter) for how to apply these filters to an image.
## Overlay
-{{< new-in "0.80.0" >}}
-
{{% funcsig %}}
images.Overlay SRC X Y
{{% /funcsig %}}
@@ -39,8 +37,6 @@ The above will overlay `$logo` in the upper left corner of `$img` (at position `
## Text
-{{< new-in "0.90.0" >}}
-
Using the `Text` filter, you can add text to an image.
{{% funcsig %}}
diff --git a/content/en/functions/int.md b/content/en/functions/int.md
index 24818cef6..33888e117 100644
--- a/content/en/functions/int.md
+++ b/content/en/functions/int.md
@@ -38,7 +38,7 @@ this purpose.
{{ int ("00987" | strings.TrimLeft "0") }}
```
-**Explanation**
+### Explanation
The `int` function eventually calls the `ParseInt` function from the Go library
`strconv`.
diff --git a/content/en/functions/intersect.md b/content/en/functions/intersect.md
index 2fe73ded8..8d4c50fe2 100644
--- a/content/en/functions/intersect.md
+++ b/content/en/functions/intersect.md
@@ -17,7 +17,7 @@ relatedfuncs: []
deprecated: false
aliases: []
---
-An useful example is to use it as `AND` filters when combined with where:
+A useful example is to use it as `AND` filters when combined with where:
## AND filter in where query
diff --git a/content/en/functions/jsonify.md b/content/en/functions/jsonify.md
index 28b90534c..72ec4634b 100644
--- a/content/en/functions/jsonify.md
+++ b/content/en/functions/jsonify.md
@@ -32,6 +32,17 @@ more copies of *indent* according to the indentation nesting.
{{ dict "title" .Title "content" .Plain | jsonify (dict "prefix" " " "indent" " ") }}
```
+## Jsonify options
+
+indent ("")
+: Indentation to use.
+
+prefix ("")
+: Indentation prefix.
+
+noHTMLEscape (false)
+: Disable escaping of problematic HTML characters inside JSON quoted strings. The default behavior is to escape &, <, and > to \u0026, \u003c, and \u003e to avoid certain safety problems that can arise when embedding JSON in HTML.
+
See also the `.PlainWords`, `.Plain`, and `.RawContent` [page variables][pagevars].
[pagevars]: /variables/page/
diff --git a/content/en/functions/markdownify.md b/content/en/functions/markdownify.md
index 171c3bf10..b108ccb94 100644
--- a/content/en/functions/markdownify.md
+++ b/content/en/functions/markdownify.md
@@ -23,7 +23,6 @@ aliases: []
{{ .Title | markdownify }}
```
-*Note*: if you need [Render Hooks][], which `markdownify` doesn't currently
-support, use [.RenderString](/functions/renderstring/) instead.
+{{< new-in "0.93.0" >}} **Note**: `markdownify` now supports [Render Hooks][] just like [.RenderString](/functions/renderstring/).
-[Render Hooks]: /getting-started/configuration-markup/#markdown-render-hooks
+[Render Hooks]: /templates/render-hooks/
diff --git a/content/en/functions/md5.md b/content/en/functions/md5.md
index 7db856a75..2168034c4 100644
--- a/content/en/functions/md5.md
+++ b/content/en/functions/md5.md
@@ -25,6 +25,6 @@ aliases: []
This can be useful if you want to use [Gravatar](https://en.gravatar.com/) for generating a unique avatar:
-```
+```html
<img src="https://www.gravatar.com/avatar/{{ md5 "[email protected]" }}?s=100&d=identicon">
```
diff --git a/content/en/functions/partialCached.md b/content/en/functions/partialCached.md
index d7a70ac64..a0c317377 100644
--- a/content/en/functions/partialCached.md
+++ b/content/en/functions/partialCached.md
@@ -43,4 +43,4 @@ If you need to pass additional parameters to create unique variants, you can pas
Note that the variant parameters are not made available to the underlying partial template. They are only use to create a unique cache key. Since Hugo `0.61.0` you can use any object as cache key(s), not just strings.
-> See also the [The Full Partial Series Part 1: Caching!](https://regisphilibert.com/blog/2019/12/hugo-partial-series-part-1-caching-with-partialcached/)
+> See also [The Full Partial Series Part 1: Caching!](https://regisphilibert.com/blog/2019/12/hugo-partial-series-part-1-caching-with-partialcached/)
diff --git a/content/en/functions/ref.md b/content/en/functions/ref.md
index ade380420..3387ce6d0 100644
--- a/content/en/functions/ref.md
+++ b/content/en/functions/ref.md
@@ -45,6 +45,6 @@ To return the absolute permalink to another Output Format of a page:
{{ ref . (dict "path" "about.md" "outputFormat" "rss") }}
```
-Hugo emits an error or warning if the page cannot be uniquely resolved. The error behavior is configurable; see [Ref and RelRef Configuration](/content-management/cross-references/#ref-and-relref-configuration).
+Hugo emits an error or warning if the page cannot be uniquely resolved. The error behavior is configurable; see [Ref and RelRef Configuration](/content-management/cross-references/#ref-and-relref-configuration).
This function is used by Hugo's built-in [`ref`](/content-management/shortcodes/#ref-and-relref) shortcode. For a detailed explanation of how to leverage this shortcode for content management, see [Links and Cross References](/content-management/cross-references/).
diff --git a/content/en/functions/relLangURL.md b/content/en/functions/relLangURL.md
index 5cca28c69..78b823c23 100644
--- a/content/en/functions/relLangURL.md
+++ b/content/en/functions/relLangURL.md
@@ -1,29 +1,62 @@
---
title: relLangURL
-description: Adds the relative URL with correct language prefix according to site configuration for multilingual.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
-keywords: [multilingual,i18n,urls]
+description: Returns a relative URL with a language prefix, if any.
categories: [functions]
menu:
docs:
- parent: "functions"
+ parent: functions
+keywords: [urls, multilingual,i18n]
signature: ["relLangURL INPUT"]
-workson: []
-hugoversion:
-relatedfuncs: []
-deprecated: false
-aliases: []
---
-`absLangURL` and `relLangURL` functions are similar to their [`absURL`](/functions/absurl/) and [`relURL`](/functions/relurl/) relatives but will add the correct language prefix when the site is configured with more than one language. (See [Configure Languages][multiliconfig].)
+Use this function with both monolingual and multilingual configurations. The URL returned by this function depends on:
-So for a site `baseURL` set to `https://example.com/hugo/` and the current language is `en`:
+- Whether the input begins with a slash
+- The `baseURL` in site configuration
+- The language prefix, if any
+In examples that follow, the project is multilingual with content in both Español (`es`) and English (`en`). The default language is Español. The returned values are from the English site.
+
+### Input does not begin with a slash
+
+If the input does not begin with a slash, the resulting URL will be correct regardless of the `baseURL`.
+
+With `baseURL = https://example.org/`
+
+```go-html-template
+{{ relLangURL "" }} → /en/
+{{ relLangURL "articles" }} → /en/articles
+{{ relLangURL "style.css" }} → /en/style.css
+```
+
+With `baseURL = https://example.org/docs/`
+
+```go-html-template
+{{ relLangURL "" }} → /docs/en/
+{{ relLangURL "articles" }} → /docs/en/articles
+{{ relLangURL "style.css" }} → /docs/en/style.css
```
-{{ "blog/" | absLangURL }} → "https://example.com/hugo/en/blog/"
-{{ "blog/" | relLangURL }} → "/hugo/en/blog/"
+
+### Input begins with a slash
+
+If the input begins with a slash, the resulting URL will be incorrect when the `baseURL` includes a subdirectory. With a leading slash, the function returns a URL relative to the protocol+host section of the `baseURL`.
+
+With `baseURL = https://example.org/`
+
+```go-html-template
+{{ relLangURL "/" }} → /en/
+{{ relLangURL "/articles" }} → /en/articles
+{{ relLangURL "/style.css" }} → /en/style.css
+```
+
+With `baseURL = https://example.org/docs/`
+
+```go-html-template
+{{ relLangURL "/" }} → /en/
+{{ relLangURL "/articles" }} → /en/articles
+{{ relLangURL "/style.css" }} → /en/style.css
```
-[multiliconfig]: /content-management/multilingual/#configure-languages
+{{% note %}}
+The last three examples are not desirable in most situations. As a best practice, never include a leading slash when using this function.
+{{% /note %}}
diff --git a/content/en/functions/relref.md b/content/en/functions/relref.md
index dbac2f3db..1f32f60a2 100644
--- a/content/en/functions/relref.md
+++ b/content/en/functions/relref.md
@@ -52,6 +52,6 @@ To return the relative permalink to another Output Format of a page:
{{ relref . (dict "path" "about.md" "outputFormat" "rss") }}
```
-Hugo emits an error or warning if the page cannot be uniquely resolved. The error behavior is configurable; see [Ref and RelRef Configuration](/content-management/cross-references/#ref-and-relref-configuration).
+Hugo emits an error or warning if the page cannot be uniquely resolved. The error behavior is configurable; see [Ref and RelRef Configuration](/content-management/cross-references/#ref-and-relref-configuration).
This function is used by Hugo's built-in [`relref`](/content-management/shortcodes/#ref-and-relref) shortcode. For a detailed explanation of how to leverage this shortcode for content management, see [Links and Cross References](/content-management/cross-references/).
diff --git a/content/en/functions/relurl.md b/content/en/functions/relurl.md
index af98c44f4..c8278c9df 100644
--- a/content/en/functions/relurl.md
+++ b/content/en/functions/relurl.md
@@ -1,49 +1,61 @@
---
title: relURL
-description: Creates a baseURL-relative URL.
-date: 2017-02-01
-publishdate: 2017-02-01
+description: Returns a relative URL.
categories: [functions]
menu:
docs:
- parent: "functions"
+ parent: functions
keywords: [urls]
signature: ["relURL INPUT"]
-workson: []
-hugoversion:
-relatedfuncs: [absURL]
-deprecated: false
-aliases: []
---
-Both `absURL` and `relURL` consider the configured value of `baseURL` in your site's [`config` file][configuration]. Given a `baseURL` set to `https://example.com/hugo/`:
+With multilingual configurations, use the [`relLangURL`] function instead. The URL returned by this function depends on:
+- Whether the input begins with a slash
+- The `baseURL` in site configuration
+
+### Input does not begin with a slash
+
+If the input does not begin with a slash, the resulting URL will be correct regardless of the `baseURL`.
+
+With `baseURL = https://example.org/`
+
+```go-html-template
+{{ relURL "" }} → /
+{{ relURL "articles" }} → /articles
+{{ relURL "style.css" }} → /style.css
```
-{{ "mystyle.css" | absURL }} → "https://example.com/hugo/mystyle.css"
-{{ "mystyle.css" | relURL }} → "/hugo/mystyle.css"
-{{ "http://gohugo.io/" | relURL }} → "http://gohugo.io/"
-{{ "http://gohugo.io/" | absURL }} → "http://gohugo.io/"
+
+With `baseURL = https://example.org/docs/`
+
+```go-html-template
+{{ relURL "" }} → /docs/
+{{ relURL "articles" }} → /docs/articles
+{{ relURL "style.css" }} → /docs/style.css
```
-The last two examples may look strange but can be very useful. For example, the following shows how to use `absURL` in [JSON-LD structured data for SEO][jsonld] where some of your images for a piece of content may or may not be hosted locally:
+### Input begins with a slash
-{{< code file="layouts/partials/schemaorg-metadata.html" download="schemaorg-metadata.html" >}}
-<script type="application/ld+json">
-{
- "@context" : "https://schema.org",
- "@type" : "BlogPosting",
- "image" : {{ apply .Params.images "absURL" "." }}
-}
-</script>
-{{< /code >}}
+If the input begins with a slash, the resulting URL will be incorrect when the `baseURL` includes a subdirectory. With a leading slash, the function returns a URL relative to the protocol+host section of the `baseURL`.
-The above uses the [apply function][] and also exposes how the Go template parser JSON-encodes objects inside `<script>` tags. See [the safeJS template function][safejs] for examples of how to tell Hugo not to escape strings inside of such tags.
+With `baseURL = https://example.org/`
+
+```go-html-template
+{{ relURL "/" }} → /
+{{ relURL "/articles" }} → /articles
+{{ relURL "style.css" }} → /style.css
+```
+
+With `baseURL = https://example.org/docs/`
+
+```go-html-template
+{{ relURL "/" }} → /
+{{ relURL "/articles" }} → /articles
+{{ relURL "/style.css" }} → /style.css
+```
-{{% note "Ending Slash" %}}
-`absURL` and `relURL` are smart about missing slashes, but they will *not* add a closing slash to a URL if it is not present.
+{{% note %}}
+The last three examples are not desirable in most situations. As a best practice, never include a leading slash when using this function.
{{% /note %}}
-[apply function]: /functions/apply/
-[configuration]: /getting-started/configuration/
-[jsonld]: https://developers.google.com/search/docs/advanced/structured-data/intro-structured-data
-[safejs]: /functions/safejs
+[`relLangURL`]: /functions/rellangurl/
diff --git a/content/en/functions/replacere.md b/content/en/functions/replacere.md
index a2149b6d3..f1e34ba65 100644
--- a/content/en/functions/replacere.md
+++ b/content/en/functions/replacere.md
@@ -1,34 +1,47 @@
---
title: replaceRE
-description: Replaces all occurrences of a regular expression with the replacement pattern.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2020-09-07
+description: Returns a string, replacing all occurrences of a regular expression with a replacement pattern.
categories: [functions]
menu:
docs:
- parent: "functions"
+ parent: functions
keywords: [regex]
-signature: ["strings.ReplaceRE PATTERN REPLACEMENT INPUT [LIMIT]", "replaceRE PATTERN REPLACEMENT INPUT [LIMIT]"]
-workson: []
-hugoversion:
-relatedfuncs: []
-deprecated: false
+signature:
+ - "replaceRE PATTERN REPLACEMENT INPUT [LIMIT]"
+ - "strings.ReplaceRE PATTERN REPLACEMENT INPUT [LIMIT]"
+relatedfuncs: [findRE]
aliases: []
---
+By default, the `replaceRE` function replaces all matches. You can limit the number of matches with an optional LIMIT paramater.
-`strings.ReplaceRE` returns a copy of `INPUT`, replacing all matches of the regular
-expression `PATTERN` with the replacement text `REPLACEMENT`.
-The number of replacements can be limited with an optional `LIMIT` parameter.
+When specifying the regular expression, use a raw [string literal] (backticks) instead of an interpreted string literal (double quotes) to simplify the syntax. With an interpreted string literal you must escape backslashes.
+The syntax of the regular expression is the same general syntax used by Perl, Python, and other languages. More precisely, it is the syntax accepted by [RE2] except for `\C`.
+
+This example replaces two or more consecutive hyphens with a single hyphen:
+
+```go-html-template
+{{ $s := "a-b--c---d" }}
+{{ replaceRE `(-{2,})` "-" $s }} → a-b-c-d
```
-{{ replaceRE "^https?://([^/]+).*" "$1" "http://gohugo.io/docs" }}` → "gohugo.io"
-{{ "http://gohugo.io/docs" | replaceRE "^https?://([^/]+).*" "$1" }}` → "gohugo.io"
-{{ replaceRE "a+b" "X" "aabbaabbab" 1 }} → "Xbaabbab"
+
+To limit the number of replacements to one:
+
+```go-html-template
+{{ $s := "a-b--c---d" }}
+{{ replaceRE `(-{2,})` "-" $s 1 }} → a-b-c---d
```
-{{% note %}}
-Hugo uses Go's [Regular Expression package](https://golang.org/pkg/regexp/), which is the same general syntax used by Perl, Python, and other languages but with a few minor differences for those coming from a background in PCRE. For a full syntax listing, see the [GitHub wiki for re2](https://github.com/google/re2/wiki/Syntax).
+You can use `$1`, `$2`, etc. within the replacement string to insert the groups captured within the regular expression:
-If you are just learning RegEx, or at least Go's flavor, you can practice pattern matching in the browser at <https://regex101.com/>.
+```go-html-template
+{{ $s := "http://gohugo.io/docs" }}
+{{ replaceRE "^https?://([^/]+).*" "$1" $s }} → gohugo.io
+```
+
+{{% note %}}
+You can write and test your regular expression using [regex101.com](https://regex101.com/). Be sure to select the Go flavor before you begin.
{{% /note %}}
+
+[RE2]: https://github.com/google/re2/wiki/Syntax
+[string literal]: https://go.dev/ref/spec#String_literals
diff --git a/content/en/functions/safeHTML.md b/content/en/functions/safeHTML.md
index 3d5197a4f..5a0aa1e05 100644
--- a/content/en/functions/safeHTML.md
+++ b/content/en/functions/safeHTML.md
@@ -27,7 +27,7 @@ copyright = "© 2015 Jane Doe. <a href=\"https://creativecommons.org/licenses/b
`{{ .Site.Copyright | safeHTML }}` in a template would then output:
-```
+```html
© 2015 Jane Doe. <a href="https://creativecommons.org/licenses/by/4.0/">Some rights reserved</a>.
```
diff --git a/content/en/functions/safeHTMLAttr.md b/content/en/functions/safeHTMLAttr.md
index 19de2e985..7e730412a 100644
--- a/content/en/functions/safeHTMLAttr.md
+++ b/content/en/functions/safeHTMLAttr.md
@@ -1,30 +1,46 @@
---
title: safeHTMLAttr
-# linktitle: safeHTMLAttr
description: Declares the provided string as a safe HTML attribute.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [functions]
menu:
docs:
- parent: "functions"
+ parent: functions
keywords: [strings]
signature: ["safeHTMLAttr INPUT"]
-workson: []
-hugoversion:
relatedfuncs: []
-deprecated: false
aliases: []
---
-Example: Given a site-wide `config.toml` that contains this menu entry:
+Given a site configuration that contains this menu entry:
{{< code-toggle file="config" >}}
[[menu.main]]
- name = "IRC: #golang at freenode"
- url = "irc://irc.freenode.net/#golang"
+ name = "IRC"
+ url = "irc://irc.freenode.net/#golang"
{{< /code-toggle >}}
-* <span class="bad">`<a href="{{ .URL }}">` &rarr; `<a href="#ZgotmplZ">`</span>
-* <span class="good">`<a {{ printf "href=%q" .URL | safeHTMLAttr }}>` &rarr; `<a href="irc://irc.freenode.net/#golang">`</span>
+Attempting to use the `url` value directly in an attribute:
+
+```go-html-template
+{{ range site.Menus.main }}
+ <a href="{{ .URL }}">{{ .Name }}</a>
+{{ end }}
+```
+
+Will produce:
+
+```html
+<a href="#ZgotmplZ">IRC</a>
+```
+
+`ZgotmplZ` is a special value, inserted by Go's [template/html] package, that indicates that unsafe content reached a CSS or URL context.
+
+To override the safety check, use the `safeHTMLAttr` function:
+
+```go-html-template
+{{ range site.Menus.main }}
+ <a {{ printf "href=%q" .URL | safeHTMLAttr }}>{{ .Name }}</a>
+{{ end }}
+```
+
+[template/html]: https://pkg.go.dev/html/template
diff --git a/content/en/functions/scratch.md b/content/en/functions/scratch.md
index c64aa1119..20f1ba14a 100644
--- a/content/en/functions/scratch.md
+++ b/content/en/functions/scratch.md
@@ -42,7 +42,7 @@ Since Hugo 0.43, there are two different ways of using Scratch:
#### The local `newScratch`
-{{< new-in "0.43" >}} A Scratch instance can also be assigned to any variable using the `newScratch` function. In this case, no Page or Shortcode context is required and the scope of the scratch is only local. The methods detailed below are available from the variable the Scratch instance was assigned to.
+A Scratch instance can also be assigned to any variable using the `newScratch` function. In this case, no Page or Shortcode context is required and the scope of the scratch is only local. The methods detailed below are available from the variable the Scratch instance was assigned to.
```go-html-template
{{ $data := newScratch }}
@@ -77,7 +77,7 @@ Get the value of a given key.
#### .Add
-Add a given value to existing value(s) of the given key.
+Add a given value to existing value(s) of the given key.
For single values, `Add` accepts values that support Go's `+` operator. If the first `Add` for a key is an array or slice, the following adds will be appended to that list.
@@ -138,7 +138,7 @@ Return an array of values from `key` sorted by `mapKey`.
#### .Delete
-{{< new-in "0.38" >}} Remove the given key.
+Remove the given key.
```go-html-template
{{ $scratch.Set "greeting" "Hello" }}
diff --git a/content/en/functions/split.md b/content/en/functions/split.md
index a66a7cf0c..51d1a64f7 100644
--- a/content/en/functions/split.md
+++ b/content/en/functions/split.md
@@ -1,10 +1,9 @@
---
title: split
-# linktitle: split
-description: splits a string into substrings separated by a delimiter
+description: Returns a slice of strings by splitting STRING by DELIM.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
+lastmod: 2022-11-06
categories: [functions]
menu:
docs:
@@ -18,4 +17,14 @@ deprecated: false
aliases: []
---
-* `{{split "tag1,tag2,tag3" "," }}` → ["tag1" "tag2" "tag3"]
+Examples:
+
+```go-html-template
+{{ split "tag1,tag2,tag3" "," }} → ["tag1", "tag2", "tag3"]
+{{ split "abc" "" }} → ["a", "b", "c"]
+```
+
+
+{{% note %}}
+`split` essentially does the opposite of [delimit]({{< ref "functions/delimit" >}}). While `split` creates a slice from a string, `delimit` creates a string from a slice.
+{{% /note %}}
diff --git a/content/en/functions/strings.Count.md b/content/en/functions/strings.Count.md
index f666a7843..c0b11233c 100644
--- a/content/en/functions/strings.Count.md
+++ b/content/en/functions/strings.Count.md
@@ -17,8 +17,6 @@ deprecated: false
aliases: []
---
-{{< new-in "0.74.0" >}}
-
If `SUBSTR` is an empty string, this function returns 1 plus the number of Unicode code points in `STRING`.
Example|Result
diff --git a/content/en/functions/strings.HasSuffix.md b/content/en/functions/strings.HasSuffix.md
index 3b82ea055..78688a5cb 100644
--- a/content/en/functions/strings.HasSuffix.md
+++ b/content/en/functions/strings.HasSuffix.md
@@ -1,6 +1,6 @@
---
title: strings.HasSuffix
-description: Determine whether or not a given string ends with the provided trailing suffix string.
+description: Determine whether a given string ends with the provided trailing suffix string.
date: 2019-08-13
publishdate: 2019-08-13
lastmod: 2019-08-13
diff --git a/content/en/functions/symdiff.md b/content/en/functions/symdiff.md
index da269a422..bac1f1ffe 100644
--- a/content/en/functions/symdiff.md
+++ b/content/en/functions/symdiff.md
@@ -21,8 +21,3 @@ Example:
The above will print `[1 2 4]`.
Also see https://en.wikipedia.org/wiki/Symmetric_difference
-
-
-
-
-
diff --git a/content/en/functions/upper.md b/content/en/functions/upper.md
index 0762541dd..c7d523217 100644
--- a/content/en/functions/upper.md
+++ b/content/en/functions/upper.md
@@ -22,7 +22,7 @@ aliases: []
Note that `upper` can be applied in your templates in more than one way:
-```
+```go-html-template
{{ upper "BatMan" }} → "BATMAN"
{{ "BatMan" | upper }} → "BATMAN"
```
diff --git a/content/en/functions/urlize.md b/content/en/functions/urlize.md
index 82a88b9d7..048946cd3 100644
--- a/content/en/functions/urlize.md
+++ b/content/en/functions/urlize.md
@@ -68,6 +68,4 @@ The preceding partial would then output to the rendered page as follows, assumin
</header>
{{< /output >}}
-
-
[singletemplate]: /templates/single-page-templates/
diff --git a/content/en/functions/urlquery.md b/content/en/functions/urlquery.md
new file mode 100644
index 000000000..ca00e6e6d
--- /dev/null
+++ b/content/en/functions/urlquery.md
@@ -0,0 +1,33 @@
+---
+title: urlquery
+linktitle: urlquery
+description: Returns the escaped value of the textual representation of its arguments in a form suitable for embedding in a URL query.
+date: 2022-01-18
+publishdate: 2022-01-18
+lastmod: 2022-01-18
+categories: [functions]
+menu:
+ docs:
+ parent: "functions"
+keywords: [urls]
+signature: ["urlquery INPUT [INPUT]..."]
+hugoversion:
+deprecated: false
+workson: []
+relatedfuncs: []
+aliases: []
+---
+
+
+This template code:
+
+```go-html-template
+{{ $u := urlquery "https://" "example.com" | safeURL }}
+<a href="https://example.org?url={{ $u }}">Link</a>
+```
+
+Is rendered to:
+
+```html
+<a href="https://example.org?url=https%3A%2F%2Fexample.com">Link</a>
+```
diff --git a/content/en/functions/urls.Parse.md b/content/en/functions/urls.Parse.md
index 7709ad8c2..676734210 100644
--- a/content/en/functions/urls.Parse.md
+++ b/content/en/functions/urls.Parse.md
@@ -19,13 +19,13 @@ aliases: []
`urls.Parse` takes a url as input
-```
+```go-html-template
{{ $url := urls.Parse "http://www.gohugo.io" }}
```
and returns a [URL](https://godoc.org/net/url#URL) structure. The struct fields are accessed via the `.` notation:
-```
+```go-html-template
{{ $url.Scheme }} → "http"
{{ $url.Host }} → "www.gohugo.io"
```
diff --git a/content/en/functions/where.md b/content/en/functions/where.md
index f712cd984..b7d31f645 100644
--- a/content/en/functions/where.md
+++ b/content/en/functions/where.md
@@ -115,7 +115,7 @@ You can also put the returned value of the `where` clauses into a variable:
Using `first` and `where` together can be very
powerful. Below snippet gets a list of posts only from [**main
-sections**](#mainsections), sorts it using the [default
+sections**]({{< relref "where.md#mainsections" >}}), sorts it using the [default
ordering](/templates/lists/) for lists (i.e., `weight => date`), and
then ranges through only the first 5 posts in that list:
@@ -163,7 +163,7 @@ section names to hard-coded values like `"posts"` or `"post"`.
```
If the user has not set this config parameter in their site config, it
-will default to the _section with the most pages_.
+will default to the *section with the most pages*.
The user can override the default:
diff --git a/content/en/getting-started/_index.md b/content/en/getting-started/_index.md
index 1615bdd91..bffc2e1b7 100644
--- a/content/en/getting-started/_index.md
+++ b/content/en/getting-started/_index.md
@@ -4,7 +4,6 @@ linktitle: Get Started Overview
description: Quick start and guides for installing Hugo on your preferred operating system.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [getting started]
keywords: [usage,docs]
menu:
@@ -12,13 +11,12 @@ menu:
parent: "getting-started"
weight: 1
weight: 0001 #rem
-draft: false
aliases: [/overview/introduction/]
toc: false
---
If this is your first time using Hugo and you've [already installed Hugo on your machine][installed], we recommend the [quick start][]. You can also use [external learning resources][] to learn Hugo.
-[installed]: /getting-started/installing/
+[installed]: /installation/
[quick start]: /getting-started/quick-start/
[external learning resources]: /getting-started/external-learning-resources/
diff --git a/content/en/getting-started/configuration-markup.md b/content/en/getting-started/configuration-markup.md
index 2a38c0ce4..4694bd439 100644
--- a/content/en/getting-started/configuration-markup.md
+++ b/content/en/getting-started/configuration-markup.md
@@ -12,8 +12,6 @@ toc: true
## Configure Markup
-{{< new-in "0.60.0" >}}
-
See [Goldmark](#goldmark) for settings related to the default Markdown handler in Hugo.
Below are all markup related configuration in Hugo with their default settings:
@@ -43,7 +41,7 @@ typographer
attribute
: Enable custom attribute support for titles and blocks by adding attribute lists inside single curly brackets (`{.myclass class="class1 class2" }`) and placing it _after the Markdown element it decorates_, on the same line for titles and on a new line directly below for blocks.
-{{< new-in "0.81.0" >}} In Hugo 0.81.0 we added support for adding attributes (e.g. CSS classes) to Markdown blocks, e.g. tables, lists, paragraphs etc.
+Hugo supports adding attributes (e.g. CSS classes) to Markdown blocks, e.g. tables, lists, paragraphs etc.
A blockquote with a CSS class:
@@ -70,15 +68,14 @@ There are some current limitations: For tables you can currently only apply it t
Note that attributes in [code fences](/content-management/syntax-highlighting/#highlighting-in-code-fences) must come after the opening tag, with any other highlighting processing instruction, e.g.:
-````
+````txt
```go {.myclass linenos=table,hl_lines=[8,"15-17"],linenostart=199}
// ... code
```
````
-autoHeadingIDType ("github") {{< new-in "0.62.2" >}}
-: The strategy used for creating auto IDs (anchor names). Available types are `github`, `github-ascii` and `blackfriday`. `github` produces GitHub-compatible IDs, `github-ascii` will drop any non-Ascii characters after accent normalization, and `blackfriday` will make the IDs compatible with [Blackfriday](#blackfriday), the default Markdown engine before Hugo 0.60. Note that if Goldmark is your default Markdown engine, this is also the strategy used in the [anchorize](/functions/anchorize/) template func.
-
+autoHeadingIDType ("github")
+: The strategy used for creating auto IDs (anchor names). Available types are `github`, `github-ascii` and `blackfriday`. `github` produces GitHub-compatible IDs, `github-ascii` will drop any non-Ascii characters after accent normalization, and `blackfriday` will make the IDs compatible with Blackfriday, the default Markdown engine before Hugo 0.60. Note that if Goldmark is your default Markdown engine, this is also the strategy used in the [anchorize](/functions/anchorize/) template func.
### Highlight
@@ -108,8 +105,6 @@ endLevel
ordered
: Whether or not to generate an ordered list instead of an unordered list.
-
## Markdown Render Hooks
See [Markdown Render Hooks](/templates/render-hooks/).
-
diff --git a/content/en/getting-started/configuration.md b/content/en/getting-started/configuration.md
index 91279712a..ebeb31f53 100644
--- a/content/en/getting-started/configuration.md
+++ b/content/en/getting-started/configuration.md
@@ -12,7 +12,6 @@ menu:
weight: 60
weight: 60
sections_weight: 60
-draft: false
aliases: [/overview/source-directory/,/overview/configuration/]
toc: true
---
@@ -23,11 +22,11 @@ Hugo uses the `config.toml`, `config.yaml`, or `config.json` (if found in the
site root) as the default site config file.
The user can choose to override that default with one or more site config files
-using the command line `--config` switch.
+using the command-line `--config` switch.
Examples:
-```
+```txt
hugo --config debugconfig.toml
hugo --config a.toml,b.toml,c.toml
```
@@ -58,7 +57,7 @@ foo = "bar"
- Files can be localized to become language specific.
-```
+```txt
├── config
│ ├── _default
│ │ ├── config.toml
@@ -74,7 +73,7 @@ foo = "bar"
│ └── params.toml
```
-Considering the structure above, when running `hugo --environment staging`, Hugo will use every settings from `config/_default` and merge `staging`'s on top of those.
+Considering the structure above, when running `hugo --environment staging`, Hugo will use every setting from `config/_default` and merge `staging`'s on top of those.
Let's take an example to understand this better. Let's say you are using Google Analytics for your website. This requires you to specify `googleAnalytics = "G-XXXXXXXX"` in `config.toml`. Now consider the following scenario:
- You don't want the Analytics code to be loaded in development i.e. in your `localhost`
@@ -92,9 +91,8 @@ This is how you need to configure your `config.toml` files considering the above
3. Similarly in `staging/config.toml` you just need to have one line:
```googleAnalytics = "G-SSSSSSSS"```
-
- Now you need to tell Hugo that you are using the staging environment. So your build command should be `hugo --environment staging` which will load the `G-SSSSSSSS` analytics code in your staging website
+ Now you need to tell Hugo that you are using the staging environment. So your build command should be `hugo --environment staging` which will load the `G-SSSSSSSS` analytics code in your staging website
{{% note %}}
Default environments are __development__ with `hugo server` and __production__ with `hugo`.
@@ -102,8 +100,6 @@ Default environments are __development__ with `hugo server` and __production__ w
## Merge Configuration from Themes
-{{< new-in "0.84.0" >}} The configuration merge described below was improved in Hugo 0.84.0 and made fully configurable. The big change/improvement was that we now, by default, do deep merging of `params` maps from themes.
-
The configuration value for `_merge` can be one of:
none
@@ -125,7 +121,7 @@ The following is the full list of Hugo-defined variables with their default
value in parentheses. Users may choose to override those values in their site
config file(s).
-### archetypeDir
+### archetypeDir
**Default value:** "archetypes"
@@ -138,9 +134,11 @@ The directory where Hugo finds archetype files (content templates). {{% module-m
The directory where Hugo finds asset files used in [Hugo Pipes](/hugo-pipes/). {{% module-mounts-note %}}
### baseURL
+
Hostname (and path) to the root, e.g. https://bep.is/
### build
+
See [Configure Build](#configure-build)
### buildDrafts (false)
@@ -162,12 +160,11 @@ Include content already expired.
Include content with publishdate in the future.
### caches
+
See [Configure File Caches](#configure-file-caches)
### cascade
-{{< new-in "0.86.0" >}}
-
Pass down default configuration values (front matter) to pages in the content tree. The options in site config is the same as in page front matter, see [Front Matter Cascade](/content-management/front-matter#front-matter-cascade).
### canonifyURLs
@@ -304,19 +301,24 @@ See [Configure Languages](/content-management/multilingual/#configure-languages)
See [Disable a Language](/content-management/multilingual/#disable-a-language)
### markup
-See [Configure Markup](/getting-started/configuration-markup).{{< new-in "0.60.0" >}}
+
+See [Configure Markup](/getting-started/configuration-markup).
### mediaTypes
+
See [Configure Media Types](/templates/output-formats/#media-types).
### menus
+
See [Add Non-content Entries to a Menu](/content-management/menus/#add-non-content-entries-to-a-menu).
### minify
+
See [Configure Minify](#configure-minify)
### module
-Module config see [Module Config](/hugo-modules/configuration/).{{< new-in "0.56.0" >}}
+
+Module config see [Module Config](/hugo-modules/configuration/).
### newContentEditor
@@ -337,6 +339,7 @@ Don't sync permission mode of files.
Don't sync modification time of files.
### outputFormats
+
See [Configure Output Formats](#configure-additional-output-formats).
### paginate
@@ -352,6 +355,7 @@ Default number of elements per page in [pagination](/templates/pagination/).
The path element used during pagination (`https://example.com/page/2`).
### permalinks
+
See [Content Management](/content-management/urls/#permalinks).
### pluralizeListTitles
@@ -367,9 +371,10 @@ Pluralize titles in lists.
The directory to where Hugo will write the final static site (the HTML files etc.).
### related
-: See [Related Content](/content-management/related/#configure-related-content).{{< new-in "0.27" >}}
-### relativeURLs
+: See [Related Content](/content-management/related/#configure-related-content).
+
+### relativeURLs
**Default value:** false
@@ -379,9 +384,10 @@ Enable this to make all relative URLs relative to content root. Note that this d
**Default value:** "ERROR"
-When using `ref` or `relref` to resolve page links and a link cannot resolved, it will be logged with this log level. Valid values are `ERROR` (default) or `WARNING`. Any `ERROR` will fail the build (`exit -1`).
+When using `ref` or `relref` to resolve page links and a link cannot be resolved, it will be logged with this log level. Valid values are `ERROR` (default) or `WARNING`. Any `ERROR` will fail the build (`exit -1`).
### refLinksNotFoundURL
+
URL to be used as a placeholder when a page reference cannot be found in `ref` or `relref`. Is used as-is.
### removePathAccents
@@ -394,7 +400,6 @@ Removes [non-spacing marks](https://www.compart.com/en/unicode/category/Mn) from
content/post/hügó.md --> https://example.org/post/hugo/
```
-
### rssLimit
**Default value:** -1 (unlimited)
@@ -402,6 +407,7 @@ content/post/hügó.md --> https://example.org/post/hugo/
Maximum number of items in the RSS feed.
### sectionPagesMenu
+
See ["Section Menu for Lazy Bloggers"](/templates/menu-templates/#section-menu-for-lazy-bloggers).
### security
@@ -409,6 +415,7 @@ See ["Section Menu for Lazy Bloggers"](/templates/menu-templates/#section-menu-f
See [Security Policy](/about/security-model/#security-policy)
### sitemap
+
Default [sitemap configuration](/templates/sitemap-template/#configuration).
### summaryLength
@@ -418,9 +425,11 @@ Default [sitemap configuration](/templates/sitemap-template/#configuration).
The length of text in words to show in a [`.Summary`](/content-management/summaries/#automatic-summary-splitting).
### taxonomies
+
See [Configure Taxonomies](/content-management/taxonomies#configure-taxonomies).
### theme
+
: See [Module Config](/hugo-modules/configuration/#module-config-imports) for how to import a theme.
### themesDir
@@ -429,19 +438,18 @@ See [Configure Taxonomies](/content-management/taxonomies#configure-taxonomies).
The directory where Hugo reads the themes from.
-### timeout
+### timeout
**Default value:** "30s"
Timeout for generating page contents, specified as a [duration](https://pkg.go.dev/time#Duration) or in milliseconds. *Note:*&nbsp;this is used to bail out of recursive content generation. You might need to raise this limit if your pages are slow to generate (e.g., because they require large image processing or depend on remote contents).
-### timeZone
-
-{{< new-in "0.87.0" >}}
+### timeZone
The time zone (or location), e.g. `Europe/Oslo`, used to parse front matter dates without such information and in the [`time` function](/functions/time/). The list of valid values may be system dependent, but should include `UTC`, `Local`, and any location in the [IANA Time Zone database](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
### title
+
Site title.
### titleCaseStyle
@@ -451,6 +459,9 @@ Site title.
See [Configure Title Case](#configure-title-case)
### uglyURLs
+
+**Default value:** false
+
When enabled, creates URL of the form `/filename.html` instead of `/filename/`.
### watch
@@ -461,22 +472,20 @@ Watch filesystem for changes and recreate as needed.
{{% note %}}
If you are developing your site on a \*nix machine, here is a handy shortcut for finding a configuration option from the command line:
-```
+```txt
cd ~/sites/yourhugosite
hugo config | grep emoji
```
which shows output like
-```
+```txt
enableemoji: true
```
{{% /note %}}
## Configure Build
-{{< new-in "0.66.0" >}}
-
The `build` configuration section contains global build-related configuration options.
{{< code-toggle file="config">}}
@@ -490,18 +499,16 @@ noJSConfigInAssets = false
useResourceCacheWhen
: When to use the cached resources in `/resources/_gen` for PostCSS and ToCSS. Valid values are `never`, `always` and `fallback`. The last value means that the cache will be tried if PostCSS/extended version is not available.
-writeStats {{< new-in "0.69.0" >}}
+writeStats
: When enabled, a file named `hugo_stats.json` will be written to your project root with some aggregated data about the build, e.g. list of HTML entities published to be used to do [CSS pruning](/hugo-pipes/postprocess/#css-purging-with-postcss). If you're only using this for the production build, you should consider placing it below [config/production](/getting-started/configuration/#configuration-directory). It's also worth mentioning that, due to the nature of the partial server builds, new HTML entities will be added when you add or change them while the server is running, but the old values will not be removed until you restart the server or run a regular `hugo` build.
-**Note** that the prime use case for this is purging of unused CSS; it is build for speed and there may be false positives (e.g. elements that isn't really a HTML element).
+**Note** that the prime use case for this is purging of unused CSS; it is built for speed and there may be false positives (e.g., detection of HTML elements that are not HTML elements).
-noJSConfigInAssets {{< new-in "0.78.0" >}}
+noJSConfigInAssets
: Turn off writing a `jsconfig.json` into your `/assets` folder with mapping of imports from running [js.Build](https://gohugo.io/hugo-pipes/js). This file is intended to help with intellisense/navigation inside code editors such as [VS Code](https://code.visualstudio.com/). Note that if you do not use `js.Build`, no file will be written.
## Configure Server
-{{< new-in "0.67.0" >}}
-
This is only relevant when running `hugo server`, and it allows to set HTTP headers during development, which allows you to test out your Content Security Policy and similar. The configuration format matches [Netlify's](https://docs.netlify.com/routing/headers/#syntax-for-the-netlify-configuration-file) with slightly more powerful [Glob matching](https://github.com/gobwas/glob):
@@ -518,7 +525,7 @@ Referrer-Policy = "strict-origin-when-cross-origin"
Content-Security-Policy = "script-src localhost:1313"
{{< /code-toggle >}}
-Since this is is "development only", it may make sense to put it below the `development` environment:
+Since this is "development only", it may make sense to put it below the `development` environment:
{{< code-toggle file="config/development/server">}}
@@ -533,10 +540,7 @@ Referrer-Policy = "strict-origin-when-cross-origin"
Content-Security-Policy = "script-src localhost:1313"
{{< /code-toggle >}}
-
-{{< new-in "0.72.0" >}}
-
-You can also specify simple redirects rules for the server. The syntax is again similar to Netlify's.
+You can also specify simple redirects rules for the server. The syntax is again similar to Netlify's.
Note that a `status` code of 200 will trigger a [URL rewrite](https://docs.netlify.com/routing/redirects/rewrites-proxies/), which is what you want in SPA situations, e.g:
@@ -548,7 +552,20 @@ status = 200
force = false
{{< /code-toggle >}}
-{{< new-in "0.76.0" >}} Setting `force=true` will make a redirect even if there is existing content in the path. Note that before Hugo 0.76 `force` was the default behaviour, but this is inline with how Netlify does it.
+Setting `force=true` will make a redirect even if there is existing content in the path. Note that before Hugo 0.76 `force` was the default behavior, but this is inline with how Netlify does it.
+
+## 404 Server Error Page
+
+{{< new-in "0.103.0" >}}
+
+Hugo will, by default, render all 404 errors when running `hugo server` with the `404.html` template. Note that if you have already added one or more redirects to your [Server Config](#configure-server), you need to add the 404 redirect explicitly, e.g:
+
+```toml
+[[redirects]]
+ from = "/**"
+ to = "/404.html"
+ status = 404
+```
## Configure Title Case
@@ -595,7 +612,7 @@ In addition to the 3 config options already mentioned, configuration key-values
For example, the following command will effectively set a website's title on Unix-like systems:
-```
+```txt
$ env HUGO_TITLE="Some Title" hugo
```
@@ -607,7 +624,7 @@ Names must be prefixed with `HUGO_` and the configuration key must be set in upp
To set config params, prefix the name with `HUGO_PARAMS_`
{{% /note %}}
-{{< new-in "0.79.0" >}} If you are using snake_cased variable names, the above will not work, so since Hugo 0.79.0 Hugo determines the delimiter to use by the first character after `HUGO`. This allows you to define environment variables on the form `HUGOxPARAMSxAPI_KEY=abcdefgh`, using any [allowed](https://stackoverflow.com/questions/2821043/allowed-characters-in-linux-environment-variable-names#:~:text=So%20names%20may%20contain%20any,not%20begin%20with%20a%20digit.) delimiter.
+If you are using snake_cased variable names, the above will not work. Hugo determines the delimiter to use by the first character after `HUGO`. This allows you to define environment variables on the form `HUGOxPARAMSxAPI_KEY=abcdefgh`, using any [allowed](https://stackoverflow.com/questions/2821043/allowed-characters-in-linux-environment-variable-names#:~:text=So%20names%20may%20contain%20any,not%20begin%20with%20a%20digit.) delimiter.
{{< todo >}}
Test and document setting params via JSON env var.
@@ -635,7 +652,6 @@ ignoreFiles = ['^/home/user/project/content/test\.md$']
Dates are important in Hugo, and you can configure how Hugo assigns dates to your content pages. You do this by adding a `frontmatter` section to your `config.toml`.
-
The default configuration is:
{{< code-toggle file="config" >}}
@@ -696,8 +712,6 @@ Hugo v0.20 introduced the ability to render your content to multiple output form
## Configure Minify
-{{< new-in "0.68.0" >}}
-
Default configuration:
{{< code-toggle config="minify" />}}
@@ -749,9 +763,9 @@ dir
## Configuration Format Specs
-* [TOML Spec][toml]
-* [YAML Spec][yaml]
-* [JSON Spec][json]
+- [TOML Spec][toml]
+- [YAML Spec][yaml]
+- [JSON Spec][json]
[`.Site.Params`]: /variables/site/
[directory structure]: /getting-started/directory-structure
diff --git a/content/en/getting-started/directory-structure.md b/content/en/getting-started/directory-structure.md
index c523219c2..05c1f55f3 100644
--- a/content/en/getting-started/directory-structure.md
+++ b/content/en/getting-started/directory-structure.md
@@ -4,7 +4,6 @@ linktitle: Directory Structure
description: Hugo's CLI scaffolds a project directory structure and then takes that single directory and uses it as the input to create a complete website.
date: 2017-01-02
publishdate: 2017-02-01
-lastmod: 2017-03-09
categories: [getting started,fundamentals]
keywords: [source, organization, directories]
menu:
@@ -13,7 +12,6 @@ menu:
weight: 50
weight: 50
sections_weight: 50
-draft: false
aliases: [/overview/source-directory/]
toc: true
---
@@ -22,9 +20,9 @@ toc: true
{{< youtube sB0HLHjgQ7E >}}
-Running the `hugo new site` generator from the command line will create a directory structure with the following elements:
+Running the `hugo new site` generator from the command-line will create a directory structure with the following elements:
-```
+```txt
.
├── archetypes
├── config.toml
@@ -36,14 +34,13 @@ Running the `hugo new site` generator from the command line will create a direct
└── themes
```
-
## Directory Structure Explained
The following is a high-level overview of each of the directories with links to each of their respective sections within the Hugo docs.
[`archetypes`](/content-management/archetypes/)
: You can create new content files in Hugo using the `hugo new` command.
-By default, Hugo will create new content files with at least `date`, `title` (inferred from the file name), and `draft = true`. This saves time and promotes consistency for sites using multiple content types. You can create your own [archetypes][] with custom preconfigured front matter fields as well.
+By default, Hugo will create new content files with at least `date`, `title` (inferred from the filename), and `draft = true`. This saves time and promotes consistency for sites using multiple content types. You can create your own [archetypes][] with custom preconfigured front matter fields as well.
[`assets`][]
: Stores all the files which need be processed by [Hugo Pipes](/hugo-pipes/). Only the files whose `.Permalink` or `.RelPermalink` are used will be published to the `public` directory. Note: assets directory is not created by default.
@@ -73,7 +70,7 @@ From **Hugo 0.31** you can have multiple static directories.
{{% /note %}}
[`resources`][]
-: Caches some files to speed up generation. Can be also used by template authors to distribute built SASS files, so you don't have to have the preprocessor installed. Note: resources directory is not created by default.
+: Caches some files to speed up generation. Can be also used by template authors to distribute built Sass files, so you don't have to have the preprocessor installed. Note: resources directory is not created by default.
[archetypes]: /content-management/archetypes/
[`assets`]: /hugo-pipes/introduction#asset-directory/
@@ -89,7 +86,7 @@ From **Hugo 0.31** you can have multiple static directories.
[lists]: /templates/list/
[pagevars]: /variables/page/
[partials]: /templates/partials/
-[searchconsole]: https://support.google.com/analytics/answer/1142414?hl=en
+[searchconsole]: https://support.google.com/webmasters/answer/9008080#zippy=%2Chtml-file-upload
[singles]: /templates/single-page-templates/
[starters]: /tools/starter-kits/
[taxonomies]: /content-management/taxonomies/
diff --git a/content/en/getting-started/external-learning-resources/index.md b/content/en/getting-started/external-learning-resources/index.md
index feb7cbb50..7102e0831 100644
--- a/content/en/getting-started/external-learning-resources/index.md
+++ b/content/en/getting-started/external-learning-resources/index.md
@@ -34,10 +34,10 @@ Hugo in Action is a step-by-step guide to using Hugo to create static websites.
### Hugo tutorial by CloudCannon
-[Step-by-step written tutorial](https://cloudcannon.com/community/learn/hugo-101/) to teach you the basics of creating a Hugo site.
+[Step-by-step written tutorial](https://cloudcannon.com/community/learn/hugo-101/) to teach you the basics of creating a Hugo site.
## Video tutorials
-### Video Playlist by Mike Dane
+* Mike Dane explains the various features of Hugo via dedicated tutorials on [YouTube](https://www.youtube.com/watch?list=PLLAZ4kZ9dFpOnyRlyS-liKL5ReHDcj4G3&v=qtIqKaDlqXo).
-Mike Dane explains the various features of Hugo via dedicated tutorials on [YouTube](https://www.youtube.com/watch?list=PLLAZ4kZ9dFpOnyRlyS-liKL5ReHDcj4G3&v=qtIqKaDlqXo).
+* [Introduction to building your first Hugo site](https://cloudcannon.com/community/learn/hugo-beginner-tutorial/) by Mike Neumegen.
diff --git a/content/en/getting-started/installing.md b/content/en/getting-started/installing.md
deleted file mode 100644
index 3fd8d0a57..000000000
--- a/content/en/getting-started/installing.md
+++ /dev/null
@@ -1,586 +0,0 @@
----
-title: Install Hugo
-linktitle: Install Hugo
-description: Install Hugo on macOS, Windows, Linux, OpenBSD, FreeBSD, and on any machine where the Go compiler tool chain can run.
-date: 2016-11-01
-publishdate: 2016-11-01
-lastmod: 2018-01-02
-categories: [getting started,fundamentals]
-authors: ["Michael Henderson"]
-keywords: [install,pc,windows,linux,macos,binary,tarball]
-menu:
- docs:
- parent: "getting-started"
- weight: 30
-weight: 30
-sections_weight: 30
-draft: false
-aliases: [/tutorials/installing-on-windows/,/tutorials/installing-on-mac/,/overview/installing/,/getting-started/install,/install/]
-toc: true
----
-
-
-{{% note %}}
-There is lots of talk about "Hugo being written in Go", but you don't need to install Go to enjoy Hugo. Just grab a precompiled binary!
-{{% /note %}}
-
-Hugo is written in [Go](https://golang.org/) with support for multiple platforms. The latest release can be found at [Hugo Releases][releases].
-
-Hugo currently provides pre-built binaries for the following:
-
-* macOS (Darwin) for x64, i386, and ARM architectures
-* Windows
-* Linux
-* OpenBSD
-* FreeBSD
-
-Hugo may also be compiled from source wherever the Go toolchain can run; e.g., on other operating systems such as DragonFly BSD, OpenBSD, Plan&nbsp;9, Solaris, and others. See <https://golang.org/doc/install/source> for the full set of supported combinations of target operating systems and compilation architectures.
-
-## Quick Install
-
-### Binary (Cross-platform)
-
-Download the appropriate version for your platform from [Hugo Releases][releases]. Once downloaded, the binary can be run from anywhere. You don't need to install it into a global location. This works well for shared hosts and other systems where you don't have a privileged account.
-
-Ideally, you should install it somewhere in your `PATH` for easy use. `/usr/local/bin` is the most probable location.
-
-### Docker
-
-We currently do not offer official Hugo images for Docker, but we do recommend these up to date distributions: https://hub.docker.com/r/klakegg/hugo/
-
-### Homebrew (macOS)
-
-If you are on macOS and using [Homebrew][brew], you can install Hugo with the following one-liner:
-
-{{< code file="install-with-homebrew.sh" >}}
-brew install hugo
-{{< /code >}}
-
-For more detailed explanations, read the installation guides that follow for installing on macOS and Windows.
-
-### MacPorts (macOS)
-
-If you are on macOS and using [MacPorts][macports], you can install Hugo with the following one-liner:
-
-{{< code file="install-with-macports.sh" >}}
-port install hugo
-{{< /code >}}
-
-### Homebrew (Linux)
-
-If you are using [Homebrew][linuxbrew] on Linux, you can install Hugo with the following one-liner:
-
-{{< code file="install-with-linuxbrew.sh" >}}
-brew install hugo
-{{< /code >}}
-
-Installation guides for Homebrew on Linux are available on their [website][linuxbrew].
-
-### Chocolatey (Windows)
-
-If you are on a Windows machine and use [Chocolatey][] for package management, you can install Hugo with the following one-liner:
-
-{{< code file="install-with-chocolatey.ps1" >}}
-choco install hugo -confirm
-{{< /code >}}
-
-Or if you need the “extended” Sass/SCSS version:
-
-{{< code file="install-extended-with-chocolatey.ps1" >}}
-choco install hugo-extended -confirm
-{{< /code >}}
-
-### Scoop (Windows)
-
-If you are on a Windows machine and use [Scoop][] for package management, you can install Hugo with the following one-liner:
-
-```bash
-scoop install hugo
-```
-
-Or install the extended version with:
-
-```bash
-scoop install hugo-extended
-```
-
-### Source
-
-#### Prerequisite Tools
-
-* [Git][installgit]
-* [GCC][] (For Windows users only)
-* [Go (at least Go 1.11)](https://golang.org/dl/)
-
-#### Fetch from GitHub
-
-Since Hugo 0.48, Hugo uses the Go Modules support built into Go 1.11 to build. The easiest way to get started is to clone Hugo in a directory outside of the GOPATH, as in the following example:
-
-{{< code file="from-gh.sh" >}}
-mkdir $HOME/src
-cd $HOME/src
-git clone https://github.com/gohugoio/hugo.git
-cd hugo
-go install --tags extended
-{{< /code >}}
-
-Remove `--tags extended` if you do not want/need Sass/SCSS support.
-
-{{% note %}}
-
-##### For installation on Windows
-
-* Substitute the `$HOME` environment variable above with `%USERPROFILE%`.
-* If you install `--tags extended` version, you may encounter this error `"gcc": executable file not found in %PATH%`
- * Please make sure you have installed `gcc` command and add it to `%PATH%`.
- * "MinGW" is recommended, it has been tested and built successfully
-
-{{% /note %}}
-
-## macOS
-
-### Assumptions
-
-1. You know how to open the macOS terminal.
-2. You're running a modern 64-bit Mac.
-3. You will use `~/Sites` as the starting point for your site. (`~/Sites` is used for example purposes. If you are familiar enough with the command line and file system, you should have no issues following along with the instructions.)
-
-### Pick Your Method
-
-There are three ways to install Hugo on your Mac
-
-1. A package manager, like [Homebrew][brew] (`brew`) or [MacPorts][macports] (`port`)
-2. Distribution (i.e., tarball)
-3. Building from Source
-
-There is no "best" way to install Hugo on your Mac. You should use the method that works best for your use case.
-
-#### Pros and Cons
-
-There are pros and cons to each of the aforementioned methods:
-
-1. **Package Manager.** Using a package manager is the simplest method and will require the least amount of work to maintain. The drawbacks aren't severe. The default package will be for the most recent release, so it will not have bug fixes until the next release (i.e., unless you install it with the `--HEAD` option in Homebrew). Releases may lag a few days behind because it has to be coordinated with another team. Nevertheless, this is the recommended installation method if you want to work from a stable, widely used source. Package managers work well and they are easy to update.
-
-2. **Tarball.** Downloading and installing from the tarball is also easy, although it requires a few more command line skills than does Homebrew. Updates are easy as well: you just repeat the process with the new binary. This gives you the flexibility to have multiple versions on your computer. If you don't want to use `brew`, then the tarball/binary is a good choice.
-
-3. **Building from Source.** Building from source is the most work. The advantage of building from source is that you don't have to wait for a release to add features or bug fixes. The disadvantage is that you need to spend more time managing the setup, which is manageable but requires more time than the preceding two options.
-
-{{% note %}}
-Since building from source is appealing to more seasoned command line users, this guide will focus more on installing Hugo via Homebrew and Tarball.
-{{% /note %}}
-
-### Install Hugo with Brew
-
-{{< youtube WvhCGlLcrF8 >}}
-
-#### Step 1: Install `brew` if you haven't already
-
-Go to the `brew` website, <https://brew.sh/>, and follow the directions there. The most important step is the installation from the command line:
-
-{{< code file="install-brew.sh" >}}
-ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
-{{< /code >}}
-
-#### Step 2: Run the `brew` Command to Install `hugo`
-
-Installing Hugo using `brew` is as easy as the following:
-
-{{< code file="install-brew.sh" >}}
-brew install hugo
-{{< /code >}}
-
-If Homebrew is working properly, you should see something similar to the following:
-
-```
-==> Downloading https://homebrew.bintray.com/bottles/hugo-0.21.sierra.bottle.tar.gz
-######################################################################### 100.0%
-==> Pouring hugo-0.21.sierra.bottle.tar.gz
-🍺 /usr/local/Cellar/hugo/0.21: 32 files, 17.4MB
-```
-
-{{% note "Installing the Latest Hugo with Brew" %}}
-Replace `brew install hugo` with `brew install hugo --HEAD` if you want the absolute latest in-development version.
-{{% /note %}}
-
-`brew` should have updated your path to include Hugo. You can confirm by opening a new terminal window and running a few commands:
-
-```
-$ # show the location of the hugo executable
-which hugo
-/usr/local/bin/hugo
-
-# show the installed version
-ls -l $( which hugo )
-lrwxr-xr-x 1 mdhender admin 30 Mar 28 22:19 /usr/local/bin/hugo -> ../Cellar/hugo/0.13_1/bin/hugo
-
-# verify that hugo runs correctly
-hugo version
-Hugo Static Site Generator v0.13 BuildDate: 2015-03-09T21:34:47-05:00
-```
-
-### Install Hugo from Tarball
-
-#### Step 1: Decide on the location
-
-When installing from the tarball, you have to decide if you're going to install the binary in `/usr/local/bin` or in your home directory. There are three camps on this:
-
-1. Install it in `/usr/local/bin` so that all the users on your system have access to it. This is a good idea because it's a fairly standard place for executables. The downside is that you may need elevated privileges to put software into that location. Also, if there are multiple users on your system, they will all run the same version. Sometimes this can be an issue if you want to try out a new release.
-
-2. Install it in `~/bin` so that only you can execute it. This is a good idea because it's easy to do, easy to maintain, and doesn't require elevated privileges. The downside is that only you can run Hugo. If there are other users on your site, they have to maintain their own copies. That can lead to people running different versions. Of course, this does make it easier for you to experiment with different releases.
-
-3. Install it in your `Sites` directory. This is not a bad idea if you have only one site that you're building. It keeps every thing in a single place. If you want to try out new releases, you can make a copy of the entire site and update the Hugo executable.
-
-All three locations will work for you. In the interest of brevity, this guide focuses on option #2.
-
-#### Step 2: Download the Tarball
-
-1. Open <https://github.com/gohugoio/hugo/releases> in your browser.
-
-2. Find the current release by scrolling down and looking for the green tag that reads "Latest Release."
-
-3. Download the current tarball for the Mac. The name will be something like `hugo_X.Y_osx-64bit.tgz`, where `X.YY` is the release number.
-
-4. By default, the tarball will be saved to your `~/Downloads` directory. If you choose to use a different location, you'll need to change that in the following steps.
-
-#### Step 3: Confirm your download
-
-Verify that the tarball wasn't corrupted during the download:
-
-```
-tar tvf ~/Downloads/hugo_X.Y_osx-64bit.tgz
--rwxrwxrwx 0 0 0 0 Feb 22 04:02 hugo_X.Y_osx-64bit/hugo_X.Y_osx-64bit.tgz
--rwxrwxrwx 0 0 0 0 Feb 22 03:24 hugo_X.Y_osx-64bit/README.md
--rwxrwxrwx 0 0 0 0 Jan 30 18:48 hugo_X.Y_osx-64bit/LICENSE.md
-```
-
-The `.md` files are documentation for Hugo. The other file is the executable.
-
-#### Step 4: Install Into Your `bin` Directory
-
-```
-# create the directory if needed
-mkdir -p ~/bin
-
-# make it the working directory
-cd ~/bin
-
-# extract the tarball
-tar -xvzf ~/Downloads/hugo_X.Y_osx-64bit.tgz
-Archive: hugo_X.Y_osx-64bit.tgz
- x ./
- x ./hugo
- x ./LICENSE.md
- x ./README.md
-
-# verify that it runs
-./hugo version
-Hugo Static Site Generator v0.13 BuildDate: 2015-02-22T04:02:30-06:00
-```
-
-You may need to add your bin directory to your `PATH` environment variable. The `which` command will check for us. If it can find `hugo`, it will print the full path to it. Otherwise, it will not print anything.
-
-```
-# check if hugo is in the path
-which hugo
-/Users/USERNAME/bin/hugo
-```
-
-If `hugo` is not in your `PATH`:
-
-1. Determine your default shell (zsh or bash).
-
- ```
- echo $SHELL
- ```
-
-2. Edit your profile.
-
- If your default shell is zsh:
-
- ```
- nano ~/.zprofile
- ```
-
- If your default shell is bash:
-
- ```
- nano ~/.bash_profile
- ```
-
-3. Insert a line to add `$HOME/bin` to your existing `PATH`.
-
- ```
- export PATH=$PATH:$HOME/bin
- ```
-
-4. Save the file by pressing Control-X, then Y.
-
-5. Close the terminal and open a new terminal to pick up the changes to your profile. Verify the change by running the `which hugo` command again.
-
-You've successfully installed Hugo.
-
-### Build from Source on Mac
-
-If you want to compile Hugo yourself, you'll need to install Go (aka Golang). You can [install Go directly from the Go website](https://golang.org/dl/) or via Homebrew using the following command:
-
-```
-brew install go
-```
-
-#### Step 1: Get the Source
-
-If you want to compile a specific version of Hugo, go to <https://github.com/gohugoio/hugo/releases> and download the source code for the version of your choice. If you want to compile Hugo with all the latest changes (which might include bugs), clone the Hugo repository:
-
-```
-git clone https://github.com/gohugoio/hugo
-```
-
-{{% warning "Sometimes \"Latest\" = \"Bugs\""%}}
-Cloning the Hugo repository directly means taking the good with the bad. By using the bleeding-edge version of Hugo, you make your development susceptible to the latest features, as well as the latest bugs. Your feedback is appreciated. If you find a bug in the latest release, [please create an issue on GitHub](https://github.com/gohugoio/hugo/issues/new).
-{{% /warning %}}
-
-#### Step 2: Compiling
-
-Make the directory containing the source your working directory and then fetch Hugo's dependencies:
-
-```
-mkdir -p src/github.com/gohugoio
-ln -sf $(pwd) src/github.com/gohugoio/hugo
-
-go get
-```
-
-This will fetch the absolute latest version of the dependencies. If Hugo fails to build, it may be the result of a dependency's author introducing a breaking change.
-
-Once you have properly configured your directory, you can compile Hugo using the following command:
-
-```
-go build -o hugo main.go
-```
-
-Then place the `hugo` executable somewhere in your `$PATH`. You're now ready to start using Hugo.
-
-## Windows
-
-The following aims to be a complete guide to installing Hugo on your Windows PC.
-
-{{< youtube G7umPCU-8xc >}}
-
-### Assumptions for Windows
-
-1. You will use `C:\Hugo\Sites` as the starting point for your new project.
-2. You will use `C:\Hugo\bin` to store executable files.
-
-### Set up Your Directories
-
-You'll need a place to store the Hugo executable, your [content][], and the generated Hugo website:
-
-1. Open Windows Explorer.
-2. Create a new folder: `C:\Hugo`, assuming you want Hugo on your C drive, although this can go anywhere
-3. Create a subfolder in the Hugo folder: `C:\Hugo\bin`
-4. Create another subfolder in Hugo: `C:\Hugo\Sites`
-
-### Technical Users
-
-1. Download the latest zipped Hugo executable from [Hugo Releases][releases].
-2. Extract all contents to your `..\Hugo\bin` folder.
-3. Open Windows Command Line (cmd, "DOS") to add the `hugo.exe` executable to your PATH
- * do `set PATH=%PATH%;C:\Hugo\bin` to have hugo in PATH for the currently opened cmd box
- * do `setx PATH "%PATH%;C:\Hugo\bin"` to have hugo in PATH for every newly opened cmd box
- * note: "setx", not "set", plus syntax 'key "val"', not 'key=val'
-
-> You may also use "Git CMD" from the [Git for Windows package](https://gitforwindows.org/) for the native Windows commands [set](https://ss64.com/nt/set.html) and [setx](https://ss64.com/nt/setx.html), but not "Git Bash", PowerShell, or any other "CLI" with different commands
-
-### Less-technical Users
-
-1. Go to the [Hugo Releases][releases] page.
-2. The latest release is announced on top. Scroll to the bottom of the release announcement to see the downloads. They're all ZIP files.
-3. Find the Windows files near the bottom (they're in alphabetical order, so Windows is last) – download either the 32-bit or 64-bit file depending on whether you have 32-bit or 64-bit Windows. (If you don't know, [see here](https://esupport.trendmicro.com/en-us/home/pages/technical-support/1038680.aspx).)
-4. Move the ZIP file into your `C:\Hugo\bin` folder.
-5. Double-click on the ZIP file and extract its contents. Be sure to extract the contents into the same `C:\Hugo\bin` folder – Windows will do this by default unless you tell it to extract somewhere else.
-6. You should now have three new files: The hugo executable (`hugo.exe`), `LICENSE`, and `README.md`.
-
-Now you need to add Hugo to your Windows PATH settings:
-
-#### For Windows 10 Users:
-
-* Right click on the **Start** button.
-* Click on **System**.
-* Click on **Advanced System Settings** on the right.
-* Click on the **Environment Variables...** button on the bottom.
-* In the User variables section, select the row labeled "Path" and click the **Edit...** button.
-* Click the **Browse...** button and select the directory to which `hugo.exe` was extracted, which is `C:\Hugo\bin` if you went by the instructions above. *The path entry should be the folder where Hugo lives and not the binary itself.*
-* Click OK at every window to exit.
-
-#### For Windows 7 and 8.x users:
-
-Windows 7 and 8.1 do not include the easy path editor included in Windows 10, so non-technical users on those platforms are advised to install a free third-party path editor like [Windows Environment Variables Editor].
-
-### Verify the Executable
-
-Run a few commands to verify that the executable is ready to run, and then build a sample site to get started.
-
-#### 1. Open a Command Prompt
-
-At the prompt, type `hugo help` and press the <kbd>Enter</kbd> key. You should see output that starts with:
-
-```
-hugo is the main command, used to build your Hugo site.
-
-Hugo is a Fast and Flexible Static Site Generator
-built with love by spf13 and friends in Go.
-
-Complete documentation is available at https://gohugo.io/.
-```
-
-If you do, then the installation is complete. If you don't, double-check the path that you placed the `hugo.exe` file in and that you typed that path correctly when you added it to your `PATH` variable. If you're still not getting the output, search the [Hugo discussion forum][forum] to see if others have already figured out our problem. If not, add a note---in the "Support" category---and be sure to include your command and the output.
-
-At the prompt, change your directory to the `Sites` directory.
-
-```
-C:\Program Files> cd C:\Hugo\Sites
-C:\Hugo\Sites>
-```
-
-#### 2. Run the Command
-
-Run the command to generate a new site. I'm using `example.com` as the name of the site.
-
-```
-C:\Hugo\Sites> hugo new site example.com
-```
-
-You should now have a directory at `C:\Hugo\Sites\example.com`. Change into that directory and list the contents. You should get output similar to the following:
-
-```
-C:\Hugo\Sites> cd example.com
-C:\Hugo\Sites\example.com> dir
-Directory of C:\hugo\sites\example.com
-
-04/13/2015 10:44 PM <DIR> .
-04/13/2015 10:44 PM <DIR> ..
-04/13/2015 10:44 PM <DIR> archetypes
-04/13/2015 10:44 PM 83 config.toml
-04/13/2015 10:44 PM <DIR> content
-04/13/2015 10:44 PM <DIR> data
-04/13/2015 10:44 PM <DIR> layouts
-04/13/2015 10:44 PM <DIR> static
- 1 File(s) 83 bytes
- 7 Dir(s) 6,273,331,200 bytes free
-```
-
-### Troubleshoot Windows Installation
-
-[@dhersam][] has created a nice video on common issues:
-
-{{< youtube c8fJIRNChmU >}}
-
-## Linux
-
-### Snap Package
-
-In any of the [Linux distributions that support snaps][snaps], you may install the "extended" Sass/SCSS version with this command:
-
-```
-snap install hugo --channel=extended
-```
-
-To install the non-extended version without Sass/SCSS support:
-
-```
-snap install hugo
-```
-
-To switch between the two, use either `snap refresh hugo --channel=extended` or `snap refresh hugo --channel=stable`.
-
-{{% note %}}
-Hugo installed via Snap can write only inside the user’s `$HOME` directory---and gvfs-mounted directories owned by the user---because of Snaps’ confinement and security model. More information is also available [in this related GitHub issue](https://github.com/gohugoio/hugo/issues/3143).
-{{% /note %}}
-
-### Debian and Ubuntu
-
-[@anthonyfok](https://github.com/anthonyfok) and friends in the [Debian Go Packaging Team](https://go-team.pages.debian.net/) maintains an official hugo [Debian package](https://packages.debian.org/hugo) which is shared with [Ubuntu](https://packages.ubuntu.com/hugo) and is installable via `apt-get`:
-
-```
-sudo apt-get install hugo
-```
-
-What this installs depends on your Debian/Ubuntu version. On Ubuntu bionic (18.04), this installs the non-extended version without Sass/SCSS support. On Ubuntu disco (19.04), this installs the extended version with Sass/SCSS support.
-
-This option is not recommended because the Hugo in Linux package managers for Debian and Ubuntu is usually a few versions behind as described [here](https://github.com/gcushen/hugo-academic/issues/703)
-
-### Arch Linux
-
-You can also install Hugo from the Arch Linux [community](https://www.archlinux.org/packages/community/x86_64/hugo/) repository. Applies also to derivatives such as Manjaro.
-
-```
-sudo pacman -S hugo
-```
-
-### Fedora, Red Hat and CentOS
-
-Fedora maintains an [official package for Hugo](https://packages.fedoraproject.org/pkgs/hugo/hugo) which may be installed with:
-
-```
-sudo dnf install hugo
-```
-
-For the latest version, the Hugo package maintained by [@daftaupe](https://github.com/daftaupe) at Fedora Copr is recommended:
-
-* <https://copr.fedorainfracloud.org/coprs/daftaupe/hugo/>
-
-See the [related discussion in the Hugo forums][redhatforum].
-
-### openSUSE Tumbleweed
-
-openSUSE maintains an [official package](https://software.opensuse.org/package/hugo) for the Tumbleweed rolling release distribution, it may be installed with:
-
-````
-sudo zypper install hugo
-````
-
-### Solus
-
-Solus includes Hugo in its package repository, it may be installed with:
-
-```
-sudo eopkg install hugo
-```
-
-## OpenBSD
-
-OpenBSD provides a package for Hugo via `pkg_add`:
-
-```
-doas pkg_add hugo
-```
-
-
-## Upgrade Hugo
-
-Upgrading Hugo is as easy as downloading and replacing the executable you’ve placed in your `PATH` or run `brew upgrade hugo` if using Homebrew.
-
-## Next Steps
-
-Now that you've installed Hugo, read the [Quick Start guide][quickstart] and explore the rest of the documentation. If you have questions, ask the Hugo community directly by visiting the [Hugo Discussion Forum][forum].
-
-[brew]: https://brew.sh/
-[macports]: https://www.macports.org/
-[Chocolatey]: https://chocolatey.org/
-[content]: /content-management/
-[@dhersam]: https://github.com/dhersam
-[forum]: https://discourse.gohugo.io
-[mage]: https://github.com/magefile/mage
-[dep]: https://github.com/golang/dep
-[highlight shortcode]: /content-management/shortcodes/#highlight
-[installgit]: https://git-scm.com/
-[GCC]: http://www.mingw.org/
-[installgo]: https://golang.org/dl/
-[linuxbrew]: https://docs.brew.sh/Homebrew-on-Linux
-[quickstart]: /getting-started/quick-start/
-[redhatforum]: https://discourse.gohugo.io/t/solved-fedora-copr-repository-out-of-service/2491
-[releases]: https://github.com/gohugoio/hugo/releases
-[Scoop]: https://scoop.sh/
-[snaps]: https://snapcraft.io/docs/installing-snapd
-[windowsarch]: https://esupport.trendmicro.com/en-us/home/pages/technical-support/1038680.aspx
-[Windows Environment Variables Editor]: https://eveditor.com/
diff --git a/content/en/getting-started/quick-start.md b/content/en/getting-started/quick-start.md
index d30ba3cfe..4fbdb1c8f 100644
--- a/content/en/getting-started/quick-start.md
+++ b/content/en/getting-started/quick-start.md
@@ -19,7 +19,7 @@ toc: true
---
{{% note %}}
-This quick start uses `macOS` in the examples. For instructions about how to install Hugo on other operating systems, see [install](/getting-started/installing).
+This quick start uses `macOS` in the examples. For instructions about how to install Hugo on other operating systems, see [install](/installation/).
It is required to have [Git installed](https://git-scm.com/downloads) to run this tutorial.
@@ -28,8 +28,10 @@ For other approaches to learning Hugo (like books or video tutorials), refer to
## Step 1: Install Hugo
+Install the **extended version of Hugo** (this is required for the current theme used).
+
{{% note %}}
-`Homebrew` and `MacPorts`, package managers for `macOS`, can be installed from [brew.sh](https://brew.sh/) or [macports.org](https://www.macports.org/) respectively. See [install](/getting-started/installing) if you are running Windows etc.
+`Homebrew` and `MacPorts`, package managers for `macOS`, can be installed from [brew.sh](https://brew.sh/) or [macports.org](https://www.macports.org/) respectively. See [install](/installation/) if you are running Windows etc.
{{% /note %}}
```bash
@@ -42,8 +44,11 @@ To verify your new install:
```bash
hugo version
+# Example output: hugo v0.104.2+extended darwin/amd64 BuildDate=unknown
```
+It should state that it is `extended`. If it does not, uninstall it and try another installation method.
+
{{< asciicast ItACREbFgvJ0HjnSNeTknxWy9 >}}
## Step 2: Create a New Site
@@ -80,7 +85,7 @@ echo theme = \"ananke\" >> config.toml
You can manually create content files (for example as `content/<CATEGORY>/<FILE>.<FORMAT>`) and provide metadata in them, however you can use the `new` command to do a few things for you (like add title and date):
-```
+```txt
hugo new posts/my-first-post.md
```
@@ -88,7 +93,7 @@ hugo new posts/my-first-post.md
Edit the newly created content file if you want, it will start with something like this:
-```markdown
+```md
---
title: "My First Post"
date: 2019-03-26T08:47:11+01:00
@@ -107,7 +112,7 @@ Now, start the Hugo server with [drafts](/getting-started/usage/#draft-future-an
{{< asciicast BvJBsF6egk9c163bMsObhuNXj >}}
-```
+```txt
▶ hugo server -D
| EN
@@ -133,7 +138,7 @@ Press Ctrl+C to stop
**Navigate to your new site at [http://localhost:1313/](http://localhost:1313/).**
-Feel free to edit or add new content and simply refresh in browser to see changes quickly. (You might need to force refresh your web browser, something like Ctrl-R usually works.)
+Feel free to edit or add new content and you will see the changes in the browser right away while the Hugo server is running. (You might need to force refresh your web browser, something like Ctrl-R usually works.)
## Step 6: Customize the Theme
@@ -143,7 +148,7 @@ Your new site already looks great, but you will want to tweak it a little before
Open up `config.toml` in a text editor:
-```
+```toml
baseURL = "https://example.org/"
languageCode = "en-us"
title = "My New Hugo Site"
@@ -164,9 +169,8 @@ For theme specific configuration options, see the [theme site](https://github.co
It is simple. Just call:
-```
+```txt
hugo -D
```
Output will be in `./public/` directory by default (`-d`/`--destination` flag to change it, or set `publishdir` in the config file).
-
diff --git a/content/en/getting-started/usage.md b/content/en/getting-started/usage.md
index fc5ae2501..edf3e82a5 100644
--- a/content/en/getting-started/usage.md
+++ b/content/en/getting-started/usage.md
@@ -1,220 +1,172 @@
---
-title: Basic Usage
-linktitle: Basic Usage
-description: Hugo's CLI is fully featured but simple to use, even for those who have very limited experience working from the command line.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
+title: Basic usage
+linktitle: Basic usage
+description: Hugo's command line interface (CLI) is fully featured but simple to use, even for those with limited experience working from the command line.
categories: [getting started]
-keywords: [usage,livereload,command line,flags]
+keywords: [usage,livereload,command,flags]
menu:
docs:
parent: "getting-started"
weight: 40
weight: 40
sections_weight: 40
-draft: false
aliases: [/overview/usage/,/extras/livereload/,/doc/usage/,/usage/]
toc: true
---
-The following is a description of the most common commands you will use while developing your Hugo project. See the [Command Line Reference][commands] for a comprehensive view of Hugo's CLI.
+## Test your installation
-## Test Installation
+After [installing] Hugo, test your installation by running:
-Once you have [installed Hugo][install], make sure it is in your `PATH`. You can test that Hugo has been installed correctly via the `help` command:
-
-```
-hugo help
+```bash
+hugo version
```
-The output you see in your console should be similar to the following:
+You should see something like:
-```
-hugo is the main command, used to build your Hugo site.
-
-Hugo is a Fast and Flexible Static Site Generator
-built with love by spf13 and friends in Go.
-
-Complete documentation is available at https://gohugo.io/.
-
-Usage:
- hugo [flags]
- hugo [command]
-
-Available Commands:
- completion Generate the autocompletion script for the specified shell
- config Print the site configuration
- convert Convert your content to different formats
- deploy Deploy your site to a Cloud provider.
- env Print Hugo version and environment info
- gen A collection of several useful generators.
- help Help about any command
- import Import your site from others.
- list Listing out various types of content
- mod Various Hugo Modules helpers.
- new Create new content for your site
- server A high performance webserver
- version Print the version number of Hugo
-
-Flags:
- -b, --baseURL string hostname (and path) to the root, e.g. https://spf13.com/
- -D, --buildDrafts include content marked as draft
- -E, --buildExpired include expired content
- -F, --buildFuture include content with publishdate in the future
- --cacheDir string filesystem path to cache directory. Defaults: $TMPDIR/hugo_cache/
- --cleanDestinationDir remove files from destination not found in static directories
- --config string config file (default is path/config.yaml|json|toml)
- --configDir string config dir (default "config")
- -c, --contentDir string filesystem path to content directory
- --debug debug output
- -d, --destination string filesystem path to write files to
- --disableKinds strings disable different kind of pages (home, RSS etc.)
- --enableGitInfo add Git revision, date, author, and CODEOWNERS info to the pages
- -e, --environment string build environment
- --forceSyncStatic copy all files when static is changed.
- --gc enable to run some cleanup tasks (remove unused cache files) after the build
- -h, --help help for hugo
- --ignoreCache ignores the cache directory
- --ignoreVendorPaths string ignores any _vendor for module paths matching the given Glob pattern
- -l, --layoutDir string filesystem path to layout directory
- --log enable Logging
- --logFile string log File path (if set, logging enabled automatically)
- --minify minify any supported output format (HTML, XML etc.)
- --noChmod don't sync permission mode of files
- --noTimes don't sync modification time of files
- --panicOnWarning panic on first WARNING log
- --poll string set this to a poll interval, e.g --poll 700ms, to use a poll based approach to watch for file system changes
- --printI18nWarnings print missing translations
- --printMemoryUsage print memory usage to screen at intervals
- --printPathWarnings print warnings on duplicate target paths etc.
- --printUnusedTemplates print warnings on unused templates.
- --quiet build in quiet mode
- --renderToMemory render to memory (only useful for benchmark testing)
- -s, --source string filesystem path to read files relative from
- --templateMetrics display metrics about template executions
- --templateMetricsHints calculate some improvement hints when combined with --templateMetrics
- -t, --theme strings themes to use (located in /themes/THEMENAME/)
- --themesDir string filesystem path to themes directory
- --trace file write trace to file (not useful in general)
- -v, --verbose verbose output
- --verboseLog verbose logging
- -w, --watch watch filesystem for changes and recreate as needed
-
-Use "hugo [command] --help" for more information about a command.
+```text
+hugo v0.105.0-0e3b42b4a9bdeb4d866210819fc6ddcf51582ffa+extended linux/amd64 BuildDate=2022-10-28T12:29:05Z VendorInfo=snap:0.105.0
```
-## The `hugo` Command
+## Display available commands
-The most common usage is probably to run `hugo` with your current directory being the input directory.
+To see a list of the available commands and flags:
-This generates your website to the `public/` directory by default, although you can customize the output directory in your [site configuration][config] by changing the `publishDir` field.
+```bash
+hugo help
+```
-The command `hugo` renders your site into `public/` dir and is ready to be deployed to your web server:
+To get help with a subcommand, use the `--help` flag. For example:
+```bash
+hugo server --help
```
+
+## Build your site
+
+To build your site, `cd` into your project directory and run:
+
+```bash
hugo
-0 draft content
-0 future content
-99 pages created
-0 paginator pages created
-16 tags created
-0 groups created
-in 90 ms
```
-## Draft, Future, and Expired Content
+The [`hugo`] command builds your site, publishing the files to the `public` directory. To publish your site to a different directory, use the [`--destination`] flag or set [`publishDir`] in your site configuration.
-Hugo allows you to set `draft`, `publishdate`, and even `expirydate` in your content's [front matter][]. By default, Hugo will not publish:
+{{% note %}}
+Hugo does not clear the `public` directory before building your site. Existing files are overwritten, but not deleted. This behavior is intentional to prevent the inadvertent removal of files that you may have added to the `public` directory after the build.
-1. Content with a future `publishdate` value
-2. Content with `draft: true` status
-3. Content with a past `expirydate` value
+Depending on your needs, you may wish to manually clear the contents of the public directory before every build.
+{{% /note %}}
-All three of these can be overridden during both local development *and* deployment by adding the following flags to `hugo` and `hugo server`, respectively, or by changing the boolean values assigned to the fields of the same name (without `--`) in your [configuration][config]:
+## Draft, future, and expired content
-1. `--buildFuture`
-2. `--buildDrafts`
-3. `--buildExpired`
+Hugo allows you to set `draft`, `date`, `publishDate`, and `expiryDate` in the [front matter] of your content. By default, Hugo will not publish content when:
-## LiveReload
-Hugo comes with [LiveReload](https://github.com/livereload/livereload-js) built in. There are no additional packages to install. A common way to use Hugo while developing a site is to have Hugo run a server with the `hugo server` command and watch for changes:
+- The `draft` value is `true`
+- The `date` is in the future
+- The `publishDate` is in the future
+- The `expiryDate` is in the past
-```
-hugo server
-0 draft content
-0 future content
-99 pages created
-0 paginator pages created
-16 tags created
-0 groups created
-in 120 ms
-Watching for changes in /Users/yourname/sites/yourhugosite/{data,content,layouts,static}
-Serving pages from /Users/yourname/sites/yourhugosite/public
-Web Server is available at http://localhost:1313/
-Press Ctrl+C to stop
+You can override the default behavior when running `hugo` or `hugo server` with command line flags:
+
+```bash
+hugo --buildDrafts # or -D
+hugo --buildExpired # or -E
+hugo --buildFuture # or -F
```
-This will run a fully functioning web server while simultaneously watching your file system for additions, deletions, or changes within the following areas of your [project organization][dirs]:
+Although you can also set these values in your site configuration, it can lead to unwanted results unless all content authors are aware of, and understand, the settings.
-* `/static/*`
-* `/content/*`
-* `/data/*`
-* `/i18n/*`
-* `/layouts/*`
-* `/themes/<CURRENT-THEME>/*`
-* `config`
+{{% note %}}
+As noted above, Hugo does not clear the `public` directory before building your site. Depending on the _current_ evaluation of the four conditions above, after the build your `public` directory may contain extraneous files from a previous build.
-Whenever you make changes, Hugo will simultaneously rebuild the site and continue to serve content. As soon as the build is finished, LiveReload tells the browser to silently reload the page.
+A common practice is to manually clear the contents of the `public` directory before each build to remove draft, expired, and future content.
+{{% /note %}}
-Most Hugo builds are so fast that you may not notice the change unless looking directly at the site in your browser. This means that keeping the site open on a second monitor (or another half of your current monitor) allows you to see the most up-to-date version of your website without the need to leave your text editor.
+## Develop and test your site
-{{% note "Closing `</body>` Tag"%}}
-Hugo injects the LiveReload `<script>` before the closing `</body>` in your templates and will therefore not work if this tag is not present..
-{{% /note %}}
+To view your site while developing layouts or creating content, `cd` into your project directory and run:
-### Redirect automatically to the page you just saved
+```bash
+hugo server
+```
-When you are working with more than one document and want to see the markup as real-time as possible it's not ideal to keep jumping between them.
-Fortunately Hugo has an easy, embedded and simple solution for this. It's the flag `--navigateToChanged`.
+The [`hugo server`] command builds your site into memory, and serves your pages using a minimal HTTP server. When you run `hugo server` it will display the URL of your local site:
-### Disable LiveReload
+```text
+Web Server is available at http://localhost:1313/
+```
-LiveReload works by injecting JavaScript into the pages Hugo generates. The script creates a connection from the browser's web socket client to the Hugo web socket server.
+While the server is running, it watches your project directory for changes to assets, configuration, content, data, layouts, translations, and static files. When it detects a change, the server rebuilds your site and refreshes your browser using [LiveReload].
-The following methods make it easy to disable LiveReload:
+Most Hugo builds are so fast that you may not notice the change unless you are looking directly at your browser.
-```
-hugo server --watch=false
-```
+### LiveReload
-Or...
+While the server is running, Hugo injects JavaScript into the generated HTML pages. The LiveReload script creates a connection from the browser to the server via web sockets. You do not need to install any software or browser plugins, nor is any configuration required.
+### Automatic redirection
+
+When editing content, if you want your browser to automatically redirect to the page you last modified, run:
+
+```bash
+hugo server --navigateToChanged
```
-hugo server --disableLiveReload
-```
-The latter flag can be omitted by adding the following:
+## Deploy your site
+
+{{% note %}}
+As noted above, Hugo does not clear the public directory before building your site. Manually clear the contents of the public directory before each build to remove draft, expired, and future content.
+{{% /note %}}
-{{< code-toggle file="config" >}}
-disableLiveReload = true
-{{< /code-toggle >}}
+When are ready to deploy your site, run:
-## Deploy Your Website
+```bash
+hugo
+```
+
+This builds your site, publishing the files to the public directory. The directory structure will look something like this:
+
+```text
+public/
+├── categories/
+│   ├── index.html
+│   └── index.xml <-- RSS feed for this section
+├── post/
+│   ├── my-first-post/
+│   │   └── index.html
+│   ├── index.html
+│   └── index.xml <-- RSS feed for this section
+├── tags/
+│   ├── index.html
+│   └── index.xml <-- RSS feed for this section
+├── index.html
+├── index.xml <-- RSS feed for the site
+└── sitemap.xml
+```
-After running `hugo server` for local web development, you need to do a final `hugo` run *without the `server` part of the command* to rebuild your site. You may then deploy your site by copying the `public/` directory to your production web server.
+In a simple hosting environment, where you typically `ftp`, `rsync`, or `scp` your files to the root of a virtual host, the contents of the `public` directory are all that you need.
-Since Hugo generates a static website, your site can be hosted *anywhere* using any web server. See [Hosting and Deployment][hosting] for methods for hosting and automating deployments contributed by the Hugo community.
+Most of our users deploy their sites using a CI/CD workflow, where a push[^1] to their GitHub or GitLab repository triggers a build and deployment. Popular providers include [AWS Amplify], [CloudCannon], [Cloudflare Pages], [GitHub Pages], [GitLab Pages], and [Netlify].
-{{% warning "Generated Files are **NOT** Removed on Site Build" %}}
-Running `hugo` *does not* remove generated files before building. This means that you should delete your `public/` directory (or the publish directory you specified via flag or configuration file) before running the `hugo` command. If you do not remove these files, you run the risk of the wrong files (e.g., drafts or future posts) being left in the generated site.
-{{% /warning %}}
+Learn more in the [hosting and deployment] section.
+[^1]: The Git repository contains the entire project directory, typically excluding the public directory because the site is built _after_ the push.
+[`--destination`]: /commands/hugo/#options
+[`hugo server`]: /commands/hugo_server/
+[`hugo`]: /commands/hugo/
+[`publishDir`]: /getting-started/configuration/#publishdir
+[AWS Amplify]: https://aws.amazon.com/amplify/
+[CloudCannon]: https://cloudcannon.com/
+[Cloudflare Pages]: https://pages.cloudflare.com/
[commands]: /commands/
-[config]: /getting-started/configuration/
-[dirs]: /getting-started/directory-structure/
[front matter]: /content-management/front-matter/
+[GitHub Pages]: https://pages.github.com/
+[GitLab Pages]: https://docs.gitlab.com/ee/user/project/pages/
+[hosting and deployment]: /hosting-and-deployment/
[hosting]: /hosting-and-deployment/
-[install]: /getting-started/installing/
+[installing]: /installation/
+[LiveReload]: https://github.com/livereload/livereload-js
+[Netlify]: https://www.netlify.com/
diff --git a/content/en/hosting-and-deployment/deployment-with-rclone.md b/content/en/hosting-and-deployment/deployment-with-rclone.md
index e9feb765a..868278740 100644
--- a/content/en/hosting-and-deployment/deployment-with-rclone.md
+++ b/content/en/hosting-and-deployment/deployment-with-rclone.md
@@ -34,7 +34,7 @@ notesforauthors:
The spoiler is that you can even deploy your entire website from any compatible OS with no configuration. Using SFTP for example:
-```
+```txt
hugo --gc --minify
rclone sync --interactive --sftp-host sftp.example.com --sftp-user www-data --sftp-ask-password public/ :sftp:www/
```
@@ -49,7 +49,7 @@ For the next commands, we will assume you configured a remote you named ``hugo-w
The above 'spoiler' commands could become:
-```
+```txt
hugo --gc --minify
rclone sync --interactive public/ hugo-www:www/
```
diff --git a/content/en/hosting-and-deployment/deployment-with-rsync.md b/content/en/hosting-and-deployment/deployment-with-rsync.md
index ad59b71f1..dec0556cf 100644
--- a/content/en/hosting-and-deployment/deployment-with-rsync.md
+++ b/content/en/hosting-and-deployment/deployment-with-rsync.md
@@ -27,7 +27,7 @@ notesforauthors:
The spoiler is that you can deploy your entire website with a command that looks like the following:
-```
+```txt
hugo && rsync -avz --delete public/ [email protected]:~/www/
```
@@ -45,13 +45,13 @@ sudo apt-get install openssh-client
Then generate your ssh key. First, create the `.ssh` directory in your home directory if it doesn't exist:
-```
+```txt
~$ cd && mkdir .ssh & cd .ssh
```
Next, execute this command to generate a new keypair called `rsa_id`:
-```
+```txt
~/.ssh/$ ssh-keygen -t rsa -q -C "For SSH" -f rsa_id
```
@@ -59,7 +59,7 @@ You'll be prompted for a passphrase, which is an extra layer of protection. Ente
To make logging in easier, add a definition for your web host to the file `~/.ssh/config` with the following command, replacing `HOST` with the IP address or hostname of your web host, and `USER` with the username you use to log in to your web host when transferring files:
-```
+```txt
~/.ssh/$ cat >> config <<EOF
Host HOST
Hostname HOST
@@ -71,13 +71,13 @@ EOF
Then copy your ssh public key to the remote server with the `ssh-copy-id` command:
-```
+```txt
~/.ssh/$ ssh-copy-id -i rsa_id.pub [email protected]
```
Now you can easily connect to the remote server:
-```
+```txt
~$ ssh user@host
Enter passphrase for key '/home/mylogin/.ssh/rsa_id':
```
@@ -88,40 +88,40 @@ Now that you can log in with your SSH key, let's create a script to automate dep
Create a new script called `deploy` the root of your Hugo tree:
-```
+```txt
~/websites/topologix.fr$ editor deploy
```
Add the following content. Replace the `USER`, `HOST`, and `DIR` values with your own values:
-```
+```bash
#!/bin/sh
USER=my-user
HOST=my-server.com
DIR=my/directory/to/topologix.fr/ # the directory where your web site files should go
-hugo && rsync -avz --delete public/ ${USER}@${HOST}:~/${DIR}
+hugo && rsync -avz --delete public/ ${USER}@${HOST}:~/${DIR} # this will delete everything on the server that's not in the local public folder
exit 0
```
-Note that `DIR` is the relative path from the remote user's home. If you have to specify a full path (for instance `/var/www/mysite/`) you must change `~/${DIR}` to `${DIR}` inside the command line. For most cases you should not have to.
+Note that `DIR` is the relative path from the remote user's home. If you have to specify a full path (for instance `/var/www/mysite/`) you must change `~/${DIR}` to `${DIR}` inside the command-line. For most cases you should not have to.
Save and close, and make the `deploy` file executable:
-```
+```txt
~/websites/topologix.fr$ chmod +x deploy
```
Now you only have to enter the following command to deploy and update your website:
-```
+```txt
~/websites/topologix.fr$ ./deploy
```
Your site builds and deploys:
-```
+```txt
Started building sites ...
Built site for language en:
0 draft content
diff --git a/content/en/hosting-and-deployment/hosting-on-21yunbox.md b/content/en/hosting-and-deployment/hosting-on-21yunbox.md
index b0ea7a7cf..fa5bb41df 100644
--- a/content/en/hosting-and-deployment/hosting-on-21yunbox.md
+++ b/content/en/hosting-and-deployment/hosting-on-21yunbox.md
@@ -4,7 +4,6 @@ linktitle: Host on 21YunBox
description: Host your Hugo site with 21YunBox's blazing fast Chinese CDN, fully-managed SSL and auto deploys from Gitee.
date: 2021-01-06
publishdate: 2021-01-06
-lastmod: 2021-01-06
categories: [hosting and deployment]
keywords: [21yunbox,hosting,deployment]
authors: [Toby Glei]
@@ -62,4 +61,5 @@ Every deploy automatically and instantly invalidates the CDN cache, so your user
Add your own domains to your site easily using 21YunBox's [custom domains](https://www.21yunbox.com/docs/#/custom-domains) guide.
## Support
+
Click [here](https://www.21yunbox.com/docs/#/contact) to contact with 21YunBox' experts if you need help.
diff --git a/content/en/hosting-and-deployment/hosting-on-aws-amplify.md b/content/en/hosting-and-deployment/hosting-on-aws-amplify.md
index 34a21e9e9..1eed59122 100644
--- a/content/en/hosting-and-deployment/hosting-on-aws-amplify.md
+++ b/content/en/hosting-and-deployment/hosting-on-aws-amplify.md
@@ -4,7 +4,6 @@ linktitle: Host on AWS Amplify
description: Develop and deploy a cloud-powered web app with AWS Amplify.
date: 2018-01-31
publishdate: 2018-01-31
-lastmod: 2018-01-31
categories: [hosting and deployment]
keywords: [amplify,hosting,deployment]
authors: [Nikhil Swaminathan]
@@ -14,7 +13,6 @@ menu:
weight: 10
weight: 10
sections_weight: 10
-draft: false
aliases: []
toc: true
---
@@ -37,12 +35,12 @@ AWS Amplify is a combination of client library, CLI toolchain, and a Console for
1. Connect a branch from your GitHub, Bitbucket, GitLab, or AWS CodeCommit repository. Connecting your repository allows Amplify to deploy updates on every code commit to a branch.
![Hugo Amplify](/images/hosting-and-deployment/hosting-on-aws-amplify/amplify-connect-repo.gif)
-1. Accept the default build settings. The Amplify Console automatically detects your Hugo build settings and output directory.
+1. Accept the default build settings. The Amplify Console automatically detects your Hugo build settings and output directory.
![Hugo Amplify](/images/hosting-and-deployment/hosting-on-aws-amplify/amplify-build-settings.png)
1. Review your changes and then choose **Save and deploy**. The Amplify Console will pull code from your repository, build changes to the backend and frontend, and deploy your build artifacts at `https://master.unique-id.amplifyapp.com`. Bonus: Screenshots of your app on different devices to find layout issues.
-## Using a Newer Version of Hugo
+## Using a newer version of Hugo
If you need to use a different, perhaps newer, version of Hugo than the version currently supported by AWS Amplify:
@@ -53,5 +51,4 @@ If you need to use a different, perhaps newer, version of Hugo than the version
1. From the selection, click **Hugo** and ensure the version field says `latest`
1. Click **Save** to save the changes.
-
[Quick Start]: /getting-started/quick-start/
diff --git a/content/en/hosting-and-deployment/hosting-on-azure-static-web-apps.md b/content/en/hosting-and-deployment/hosting-on-azure-static-web-apps.md
index 9d9daa578..cf06580e7 100644
--- a/content/en/hosting-and-deployment/hosting-on-azure-static-web-apps.md
+++ b/content/en/hosting-and-deployment/hosting-on-azure-static-web-apps.md
@@ -18,6 +18,6 @@ toc: true
aliases: []
---
-You can create and deploy a Hugo web application to Azure Static Web Apps. The final result is a new Azure Static Web App with associated GitHub Actions that give you control over how the app is built and published. You'll learn how to create a Hugo app, setup an Azure Static Web App and deploy the Hugo app to Azure.
+You can create and deploy a Hugo web application to Azure Static Web Apps. The final result is a new Azure Static Web App with associated GitHub Actions that give you control over how the app is built and published. You'll learn how to create a Hugo app, set up an Azure Static Web App and deploy the Hugo app to Azure.
Here's the tutorial on how to [Publish a Hugo site to Azure Static Web Apps](https://docs.microsoft.com/en-us/azure/static-web-apps/publish-hugo).
diff --git a/content/en/hosting-and-deployment/hosting-on-azure.md b/content/en/hosting-and-deployment/hosting-on-azure.md
new file mode 100644
index 000000000..f63c0153c
--- /dev/null
+++ b/content/en/hosting-and-deployment/hosting-on-azure.md
@@ -0,0 +1,101 @@
+---
+title: Host on Azure Static Web Apps
+linktitle: Host on Azure Static Web Apps
+description: Deploy Hugo to Azure Static Web Apps and automate the whole process with Github Action Workflow
+date: 2021-03-12
+publishdate: 2021-03-12
+categories: [hosting and deployment]
+keywords: [azure,git,deployment,hosting]
+authors: [Aaron Powell]
+menu:
+ docs:
+ parent: "hosting-and-deployment"
+ weight: 10
+weight: 10
+sections_weight: 10
+toc: true
+---
+
+[Azure Static Web Apps] is a service that automatically builds and deploys full stack web apps to Azure from a Git repository, using [GitHub Actions] or [Azure DevOps].
+
+_The following documentation covers how to use GitHub Actions for the deployment. If you are using Azure DevOps, follow the Microsoft documentation._
+
+## Assumptions
+
+1. You have Git 2.8 or greater [installed on your machine][installgit].
+2. You have a GitHub account. [Signing up][ghsignup] for GitHub is free.
+3. You have an Azure account. You can sign up for a [Free Trail][azuretrial].
+4. You have a ready-to-publish Hugo website or have at least completed the [Quick Start][].
+
+## Deploy Hugo to Azure Static Web Apps
+
+1. Navigate to the [Azure Portal][azureportal]
+2. Click **Create a Resource**
+3. Search for **Static Web Apps**
+4. Click **Static Web Apps**
+5. Click **Create**
+
+![Create in Azure Portal](/images/hosting-and-deployment/hosting-on-azure/create-in-portal.png)
+
+6. For **Subscription**, accept the subscription that is listed or select a new one from the drop-down list.
+7. In _Resource group_, select **New**. In _New resource group name_, enter **hugo-static-app** and select **OK**.
+8. Next, a name for your app in the **Name** box. Valid characters include `a-z`, `A-Z`, `0-9` and `-`.
+9. For _Region_, select an available region close to you.
+10. For _SKU_, select **Free**.
+
+![Basic app details](/images/hosting-and-deployment/hosting-on-azure/basic-app-details.png)
+
+11. Click the **Sign in with GitHub** button.
+12. Select the **Organization** under which your repo exists.
+13. Select the Hugo app you wish to deploy as the _Repository_ .
+14. For the _Branch_ select the branch you want to deploy (eg: **main**).
+15. Select **Hugo** under the _Build Presets_, which will populate the configuration files with the standard Hugo build options
+ * **App Location** is the path in the Git repo where Hugo's config file is
+ * **Api Location** is the path where the Serverless API is (or left blank if there is no API)
+ * **Artifact Location** is the path where Hugo publishes to
+16. Click **Review + Create** to review the details and then **Create** to start the creation of the Azure Static Web Apps and create the GitHub Action workflow for deployment.
+
+A GitHub Action workflow will immediately start a build using Hugo and deployment to Azure. The website can be accessed via the URL shown on the _Overview_ page of the Azure Static Web Apps resource in Azure.
+
+## Using A Custom Hugo Version
+
+When you create a Static Web App, a [workflow file][swaconfig] is generated which contains the deployment settings for the site. You can configure a specific Hugo version in the workflow file by providing a value for `HUGO_VERSION` in the `env` section of the `Azure/static-web-apps-deploy` GitHub Action.
+
+```yaml
+jobs:
+ build_and_deploy_job:
+ if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.action != 'closed')
+ runs-on: ubuntu-latest
+ name: Build and Deploy Job
+ steps:
+ - uses: actions/checkout@v3
+ with:
+ submodules: true
+ - name: Build And Deploy
+ id: builddeploy
+ uses: Azure/static-web-apps-deploy@v1
+ with:
+ azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN }}
+ repo_token: ${{ secrets.GITHUB_TOKEN }}
+ action: "upload"
+ app_location: "/" # App source code path
+ api_location: "api" # Api source code path - optional
+ output_location: "public" # Built app content directory - optional
+ env:
+ HUGO_VERSION: 0.100.2
+```
+
+## Use a Custom Domain
+
+Azure Static Web Apps supports custom domains as a CNAME or APEX domain mapping. You can configure the custom domains via the Azure Portal. Refer to the [official documentation for custom domains][domains] for more information.
+
+[Azure Static Web Apps]: https://docs.microsoft.com/azure/static-web-apps/?WT.mc_id=javascript-26008-aapowell
+[GitHub Actions]: https://docs.github.com/en/actions
+[Azure DevOps]: https://docs.microsoft.com/azure/static-web-apps/publish-devops?WT.mc_id=javascript-26008-aapowell
+[ghsignup]: https://github.com/join
+[installgit]: https://git-scm.com/downloads
+[azuretrial]: https://azure.microsoft.com/free/?WT.mc_id=javascript-26008-aapowell
+[azureportal]: https://portal.azure.com/
+[swaconfig]: https://docs.microsoft.com/azure/static-web-apps/github-actions-workflow?WT.mc_id=javascript-26008-aapowell
+[domains]: https://docs.microsoft.com/azure/static-web-apps/custom-domain?WT.mc_id=javascript-26008-aapowell
+[Quick Start]: /getting-started/quick-start/
diff --git a/content/en/hosting-and-deployment/hosting-on-firebase.md b/content/en/hosting-and-deployment/hosting-on-firebase.md
index 3a4039f90..fe6cca1e1 100644
--- a/content/en/hosting-and-deployment/hosting-on-firebase.md
+++ b/content/en/hosting-and-deployment/hosting-on-firebase.md
@@ -4,7 +4,6 @@ linktitle: Host on Firebase
description: You can use Firebase's free tier to host your static website; this also gives you access to Firebase's NOSQL API.
date: 2017-03-12
publishdate: 2017-03-12
-lastmod: 2017-03-15
categories: [hosting and deployment]
keywords: [hosting,firebase]
authors: [Michel Racic]
@@ -14,7 +13,6 @@ menu:
weight: 20
weight: 20
sections_weight: 20
-draft: false
toc: true
aliases: []
---
@@ -28,21 +26,23 @@ aliases: []
Go to the [Firebase console][console] and create a new project (unless you already have a project). You will need to globally install `firebase-tools` (node.js):
-```
+```txt
npm install -g firebase-tools
```
Log in to Firebase (setup on your local machine) using `firebase login`, which opens a browser where you can select your account. Use `firebase logout` in case you are already logged in but to the wrong account.
-```
+```txt
firebase login
```
+
In the root of your Hugo project, initialize the Firebase project with the `firebase init` command:
-```
+```txt
firebase init
```
+
From here:
1. Choose Hosting in the feature question
@@ -51,24 +51,54 @@ From here:
4. Accept the default for the publish directory, which is `public`
5. Choose "No" in the question if you are deploying a single-page app
-## Deploy
+## Using Firebase & Github CI/CD
-To deploy your Hugo site, execute the `firebase deploy` command, and your site will be up in no time:
+In new versions of Firebase, some other questions apply:
+
+6. Set up automatic builds and deploys with GitHub?
+
+Here you will be redirected to login in your GitHub account to get permissions. Confirm.
+
+7. For which GitHub repository would you like to set up a GitHub workflow? (format: user/repository)
+
+Include the repository you will use in the format above (Account/Repo)
+Firebase script with retrive credentials, create a service account you can later manage in yout github settings.
+
+8. Set up the workflow to run a build script before every deploy?
+
+Here is your oportunity to include some commands before you run the deploy.
+
+9. Set up automatic deployment to your site's live channel when a PR is merged?
+
+You can let in the default option (main)
+
+After that Firebase has been set in your project with CI/CD. After that run:
```
hugo && firebase deploy
```
-## CI Setup
+With this you will have the app initialized manualy. After that you can manage and fix your github workflow from: https://github.com/your-account/yout-repo/actions
-You can generate a deploy token using
+Don't forget to update your static pages before push!
+
+## Manual Deploy
+To deploy your Hugo site, execute the `firebase deploy` command, and your site will be up in no time:
+```txt
+hugo && firebase deploy
```
+
+## CI Setup (Other tools)
+
+You can generate a deploy token using
+
+```txt
firebase login:ci
```
-You can also set up your CI (e.g., with [Wercker][]) and add the token to a private variable like `$FIREBASE_DEPLOY_TOKEN`.
+You can also set up your CI and add the token to a private variable like `$FIREBASE_DEPLOY_TOKEN`.
{{% note %}}
This is a private secret and it should not appear in a public repository. Make sure you understand your chosen CI and that it's not visible to others.
@@ -76,7 +106,7 @@ This is a private secret and it should not appear in a public repository. Make s
You can then add a step in your build to do the deployment using the token:
-```
+```txt
firebase deploy --token $FIREBASE_DEPLOY_TOKEN
```
@@ -84,6 +114,6 @@ firebase deploy --token $FIREBASE_DEPLOY_TOKEN
* [Firebase CLI Reference](https://firebase.google.com/docs/cli/#administrative_commands)
-[console]: https://console.firebase.google.com
+[console]: https://console.firebase.google.com/
[Quick Start]: /getting-started/quick-start/
[signup]: https://console.firebase.google.com/
diff --git a/content/en/hosting-and-deployment/hosting-on-github.md b/content/en/hosting-and-deployment/hosting-on-github.md
index 22acca568..35550ed99 100644
--- a/content/en/hosting-and-deployment/hosting-on-github.md
+++ b/content/en/hosting-and-deployment/hosting-on-github.md
@@ -43,11 +43,11 @@ The GitHub Actions used in these instructions pull source content from the `main
As mentioned in the [GitHub Pages documentation][ghorgs], you can host a user/organization page in addition to project pages. Here are the key differences in GitHub Pages websites for Users and Organizations:
1. You must create a repository named `<USERNAME>.github.io` or `<ORGANIZATION>.github.io` to host your pages
-2. By default, content from the `main` branch is used to publish GitHub Pages - rather than the `gh-pages` branch which is the default for project sites. However, the GitHub Actions in these instructions publish to the `gh-pages` branch. Therefore, if you are publishing Github pages for a user or organization, you will need to change the publishing branch to `gh-pages`. See the instructions later in this document.
+2. By default, content from the `main` branch is used to publish GitHub Pages - rather than the `gh-pages` branch which is the default for project sites. However, the GitHub Actions in these instructions publish to the `gh-pages` branch. Therefore, if you are publishing GitHub pages for a user or organization, you will need to change the publishing branch to `gh-pages`. See the instructions later in this document.
## Build Hugo With GitHub Action
-GitHub executes your software development workflows. Everytime you push your code on the GitHub repository, Github Actions will build the site automatically.
+GitHub executes your software development workflows. Every time you push your code on the GitHub repository, GitHub Actions will build the site automatically.
Create a file in `.github/workflows/gh-pages.yml` containing the following content (based on [actions-hugo](https://github.com/marketplace/actions/hugo-setup)):
@@ -57,7 +57,7 @@ name: github pages
on:
push:
branches:
- - main # Set a branch to deploy
+ - main # Set a branch that will trigger a deployment
pull_request:
jobs:
diff --git a/content/en/hosting-and-deployment/hosting-on-gitlab.md b/content/en/hosting-and-deployment/hosting-on-gitlab.md
index 03c7776a7..6eb816171 100644
--- a/content/en/hosting-and-deployment/hosting-on-gitlab.md
+++ b/content/en/hosting-and-deployment/hosting-on-gitlab.md
@@ -55,7 +55,7 @@ pages:
See [this list](https://gitlab.com/pages/hugo/container_registry) if you wish to use a particular Hugo version to build your site.
{{% /note %}}
-## Push Your Hugo Website to GitLab
+## Push your Hugo website to GitLab
Next, create a new repository on GitLab. It is *not* necessary to make the repository public. In addition, you might want to add `/public` to your .gitignore file, as there is no need to push compiled assets to GitLab or keep your output website in version control.
@@ -73,13 +73,13 @@ git remote add origin https://gitlab.com/YourUsername/your-hugo-site.git
git push -u origin master
```
-## Wait for Your Page to Build
+## Wait for your page to build
That's it! You can now follow the CI agent building your page at `https://gitlab.com/<YourUsername>/<your-hugo-site>/pipelines`.
After the build has passed, your new website is available at `https://<YourUsername>.gitlab.io/<your-hugo-site>/`.
-## Next Steps
+## Next steps
GitLab supports using custom CNAME's and TLS certificates. For more details on GitLab Pages, see the [GitLab Pages setup documentation](https://about.gitlab.com/2016/04/07/gitlab-pages-setup/).
diff --git a/content/en/hosting-and-deployment/hosting-on-keycdn.md b/content/en/hosting-and-deployment/hosting-on-keycdn.md
index bec8b36e4..85a5ab5f4 100644
--- a/content/en/hosting-and-deployment/hosting-on-keycdn.md
+++ b/content/en/hosting-and-deployment/hosting-on-keycdn.md
@@ -1,7 +1,7 @@
---
-title: "Hosting on KeyCDN"
+title: "Host on KeyCDN"
date: 2017-09-12
-description: "Accelerate your Hugo site globally with a KeyCDN integration. This tutorial shows you how to setup your static site as a GitLab page behind a KeyCDN pull zone."
+description: "Accelerate your Hugo site globally with a KeyCDN integration. This tutorial shows you how to set up your static site as a GitLab page behind a KeyCDN pull zone."
categories: [hosting and deployment]
keywords: [keycdn,hosting,deployment,cdn]
menu:
@@ -11,7 +11,6 @@ menu:
slug: ""
aliases: []
toc: false
-draft: false
---
[KeyCDN](https://www.keycdn.com/) provides a multitude of features to help accelerate and secure your Hugo site globally including Brotli compression, Let's Encrypt support, Origin Shield, and more.
@@ -24,7 +23,7 @@ draft: false
## Create a KeyCDN Pull Zone
-The first step will be to login to your KeyCDN account and create a new zone. Name this whatever you like and select the [Pull Zone](https://www.keycdn.com/support/create-a-pull-zone/) option. As for the origin URL, your site will be running on [GitLab Pages](https://docs.gitlab.com/ee/user/project/pages/getting_started_part_one.html) with a URL of `https://youruser.gitlab.io/reponame/`. Use this as the Origin URL.
+The first step will be to log in to your KeyCDN account and create a new zone. Name this whatever you like and select the [Pull Zone](https://www.keycdn.com/support/create-a-pull-zone/) option. As for the origin URL, your site will be running on [GitLab Pages](https://docs.gitlab.com/ee/user/project/pages/getting_started_part_one.html) with a URL of `https://youruser.gitlab.io/reponame/`. Use this as the Origin URL.
![Screenshot of KeyCDN's pull zone creation page](/images/hosting-and-deployment/hosting-on-keycdn/keycdn-pull-zone.png)
@@ -36,7 +35,7 @@ Ensure that you use your Zone URL or Zone alias as the `BASEURL` variable in the
Your `.gitlab-ci.yml` file should look similar to the example below. Be sure to modify any variables that are specific to your setup.
-```
+```yml
image: alpine:latest
variables:
@@ -82,7 +81,7 @@ The Zone ID and API key are used to purge your zone – it’s not strictly need
Now it’s time to push the newly created repository to GitLab:
-```
+```bash
git remote add origin [email protected]:youruser/ci-example.git
git push -u origin master
```
diff --git a/content/en/hosting-and-deployment/hosting-on-netlify.md b/content/en/hosting-and-deployment/hosting-on-netlify.md
index 1e2da8466..526795655 100644
--- a/content/en/hosting-and-deployment/hosting-on-netlify.md
+++ b/content/en/hosting-and-deployment/hosting-on-netlify.md
@@ -4,7 +4,6 @@ linktitle: Host on Netlify
description: Netlify can host your Hugo site with CDN, continuous deployment, 1-click HTTPS, an admin GUI, and its own CLI.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-03-11
categories: [hosting and deployment]
keywords: [netlify,hosting,deployment]
authors: [Ryan Watters, Seth MacLeod]
@@ -14,7 +13,6 @@ menu:
weight: 10
weight: 10
sections_weight: 10
-draft: false
aliases: []
toc: true
---
@@ -39,7 +37,7 @@ Selecting GitHub will bring up an authorization modal for authentication. Select
![Screenshot of the authorization popup for Netlify and GitHub.](/images/hosting-and-deployment/hosting-on-netlify/netlify-first-authorize.jpg)
-## Create a New Site with Continuous Deployment
+## Create a new site with continuous deployment
You're now already a Netlify member and should be brought to your new dashboard. Select "New site from git."
@@ -57,9 +55,9 @@ Select the repo you want to use for continuous deployment. If you have a large n
![Screenshot of step 1 of create a new site for Netlify: selecting the git provider](/images/hosting-and-deployment/hosting-on-netlify/netlify-create-new-site-step-2.jpg)
-Once selected, you'll be brought to a screen for basic setup. Here you can select the branch you wanted published, your [build command][], and your publish (i.e. deploy) directory. The publish directory should mirror that of what you've set in your [site configuration][config], the default of which is `public`. The following steps assume you are publishing from the `master` branch.
+Once selected, you'll be brought to a screen for basic setup. Here you can select the branch you want to publish, your [build command][], and your publish (i.e. deploy) directory. The publish directory should mirror that of what you've set in your [site configuration][config], the default of which is `public`. The following steps assume you are publishing from the `master` branch.
-## Configure Hugo Version in Netlify
+## Configure Hugo version in Netlify
You can [set Hugo version](https://www.netlify.com/blog/2017/04/11/netlify-plus-hugo-0.20-and-beyond/) for your environments in `netlify.toml` file or set `HUGO_VERSION` as a build environment variable in the Netlify console.
@@ -67,14 +65,14 @@ For production:
{{< code file="netlify.toml" codeLang="toml" >}}
[context.production.environment]
- HUGO_VERSION = "0.83.1"
+ HUGO_VERSION = "0.99.1"
{{< /code >}}
For testing:
{{< code file="netlify.toml" codeLang="toml" >}}
[context.deploy-preview.environment]
- HUGO_VERSION = "0.83.1"
+ HUGO_VERSION = "0.99.1"
{{< /code >}}
The Netlify configuration file can be a little hard to understand and get right for the different environment, and you may get some inspiration and tips from this site's `netlify.toml`:
@@ -107,7 +105,7 @@ The [`git clone` method for installing themes][installthemes] is not supported b
A *better* approach is to install a theme as a proper git submodule. You can [read the GitHub documentation for submodules][ghsm] or those found on [Git's website][gitsm] for more information, but the command is similar to that of `git clone`:
-```
+```txt
cd themes
git submodule add https://github.com/<THEMECREATOR>/<THEMENAME>
```
@@ -116,7 +114,7 @@ It is recommended to only use stable versions of a theme (if it’s versioned) a
Switch to the theme's directory and list all available versions:
-```
+```txt
cd themes/<theme>
git tag
# exit with q
@@ -124,25 +122,24 @@ git tag
You can checkout a specific version as follows:
-```
+```txt
git checkout tags/<version-name>
```
You can update a theme to the latest version by executing the following command in the *root* directory of your project:
-```
+```txt
git submodule update --rebase --remote
```
## Next Steps
-You now have a live website served over https, distributed through CDN, and configured for continuous deployment. Dig deeper into the Netlify documentation:
+You now have a live website served over HTTPS, distributed through CDN, and configured for continuous deployment. Dig deeper into the Netlify documentation:
1. [Using a Custom Domain][]
2. [Setting up HTTPS on Custom Domains][httpscustom]
3. [Redirects and Rewrite Rules][]
-
[app.netlify.com]: https://app.netlify.com
[build command]: /getting-started/usage/#the-hugo-command
[config]: /getting-started/configuration/
diff --git a/content/en/hosting-and-deployment/hosting-on-render.md b/content/en/hosting-and-deployment/hosting-on-render.md
index 73b20bcb2..40cb2c32e 100644
--- a/content/en/hosting-and-deployment/hosting-on-render.md
+++ b/content/en/hosting-and-deployment/hosting-on-render.md
@@ -37,9 +37,9 @@ Static sites are **completely free** on Render and include the following:
## Assumptions
-* You have an account with GitHub or GitLab.
-* You have completed the [Quick Start][] or have a Hugo website you are ready to deploy and share with the world.
-* You have a Render account. You can sign up at https://render.com/register.
+- You have an account with GitHub or GitLab.
+- You have completed the [Quick Start][] or have a Hugo website you are ready to deploy and share with the world.
+- You have a Render account. You can sign up at https://render.com/register.
## Deployment
diff --git a/content/en/hugo-modules/_index.md b/content/en/hugo-modules/_index.md
index 2b02a559e..b2951da9a 100644
--- a/content/en/hugo-modules/_index.md
+++ b/content/en/hugo-modules/_index.md
@@ -24,7 +24,7 @@ You can combine modules in any combination you like, and even mount directories
Hugo Modules are powered by Go Modules. For more information about Go Modules, see:
- [https://github.com/golang/go/wiki/Modules](https://github.com/golang/go/wiki/Modules)
-- [https://blog.golang.org/using-go-modules](https://blog.golang.org/using-go-modules)
+- [https://go.dev/blog/using-go-modules](https://go.dev/blog/using-go-modules)
This is all very much brand new and there are only a few example projects around:
diff --git a/content/en/hugo-modules/configuration.md b/content/en/hugo-modules/configuration.md
index 70de492ab..c05201f8a 100644
--- a/content/en/hugo-modules/configuration.md
+++ b/content/en/hugo-modules/configuration.md
@@ -26,12 +26,11 @@ replacements = ""
workspace = ""
{{< /code-toggle >}}
-
-noVendor {{< new-in "0.75.0" >}}
+noVendor
: A optional Glob pattern matching module paths to skip when vendoring, e.g. "github.com/**"
-vendorClosest {{< new-in "0.81.0" >}}
-: When enabled, we will pick the vendored module closest to the module using it. The default behaviour is to pick the first. Note that there can still be only one dependency of a given module path, so once it is in use it cannot be redefined.
+vendorClosest
+: When enabled, we will pick the vendored module closest to the module using it. The default behavior is to pick the first. Note that there can still be only one dependency of a given module path, so once it is in use it cannot be redefined.
proxy
: Defines the proxy server to use to download remote modules. Default is `direct`, which means "git clone" and similar.
@@ -42,15 +41,15 @@ noProxy
private
: Comma separated glob list matching paths that should be treated as private.
-workspace {{< new-in "0.83.0" >}}
+workspace
: The workspace file to use. This enables Go workspace mode. Note that this can also be set via OS env, e.g. `export HUGO_MODULE_WORKSPACE=/my/hugo.work` This only works with Go 1.18+.
-replacements {{< new-in "0.77.0" >}}
+replacements
: A comma separated (or a slice) list of module path to directory replacement mapping, e.g. `github.com/bep/my-theme -> ../..,github.com/bep/shortcodes -> /some/path`. This is mostly useful for temporary locally development of a module, and then it makes sense to set it as an OS environment variable, e.g: `env HUGO_MODULE_REPLACEMENTS="github.com/bep/my-theme -> ../.."`. Any relative path is relate to [themesDir](https://gohugo.io/getting-started/configuration/#all-configuration-settings), and absolute paths are allowed.
Note that the above terms maps directly to their counterparts in Go Modules. Some of these setting may be natural to set as OS environment variables. To set the proxy server to use, as an example:
-```
+```txt
env HUGO_MODULE_PROXY=https://proxy.example.org hugo
```
@@ -99,13 +98,13 @@ path
ignoreConfig
: If enabled, any module configuration file, e.g. `config.toml`, will not be loaded. Note that this will also stop the loading of any transitive module dependencies.
-ignoreImports {{< new-in "0.80.0" >}}
+ignoreImports
: If enabled, module imports will not be followed.
disable
: Set to `true` to disable the module while keeping any version info in the `go.*` files.
-noMounts {{< new-in "0.84.2" >}}
+noMounts
: Do not mount any folder in this import.
noVendor
@@ -113,7 +112,6 @@ noVendor
{{< gomodules-info >}}
-
## Module Config: mounts
{{% note %}}
@@ -160,14 +158,11 @@ lang
: The language code, e.g. "en". Only relevant for `content` mounts, and `static` mounts when in multihost mode.
includeFiles (string or slice)
-: One or more [glob](https://github.com/gobwas/glob) patterns matching files or directories to include. If `excludeFiles` is not set, the files matching `includeFiles` will be the files mounted.
+: One or more [glob](https://github.com/gobwas/glob) patterns matching files or directories to include. If `excludeFiles` is not set, the files matching `includeFiles` will be the files mounted.
The glob patterns are matched to the filenames starting from the `source` root, they should have Unix styled slashes even on Windows, `/` matches the mount root and `**` can be used as a super-asterisk to match recursively down all directories, e.g `/posts/**.jpg`.
The search is case-insensitive.
-{{< new-in "0.89.0" >}}
-
excludeFiles (string or slice)
: One or more glob patterns matching files to exclude.
-
diff --git a/content/en/hugo-modules/theme-components.md b/content/en/hugo-modules/theme-components.md
index f1feb636a..c78b4249b 100644
--- a/content/en/hugo-modules/theme-components.md
+++ b/content/en/hugo-modules/theme-components.md
@@ -25,7 +25,6 @@ Since Hugo `0.42` a project can configure a theme as a composite of as many them
theme = ["my-shortcodes", "base-theme", "hyde"]
{{< /code-toggle >}}
-
You can even nest this, and have the theme component itself include theme components in its own `config.toml` (theme inheritance).[^1]
The theme definition example above in `config.toml` creates a theme with 3 theme components with precedence from left to right.
@@ -34,7 +33,7 @@ For any given file, data entry, etc., Hugo will look first in the project and th
Hugo uses two different algorithms to merge the filesystems, depending on the file type:
-* For `i18n` and `data` files, Hugo merges deeply using the translation id and data key inside the files.
+* For `i18n` and `data` files, Hugo merges deeply using the translation ID and data key inside the files.
* For `static`, `layouts` (templates), and `archetypes` files, these are merged on file level. So the left-most file will be chosen.
The name used in the `theme` definition above must match a folder in `/your-site/themes`, e.g. `/your-site/themes/my-shortcodes`. There are plans to improve on this and get a URL scheme so this can be resolved automatically.
@@ -47,8 +46,4 @@ Also note that a component that is part of a theme can have its own configuratio
The same rules apply here: The left-most param/menu etc. with the same ID will win. There are some hidden and experimental namespace support in the above, which we will work to improve in the future, but theme authors are encouraged to create their own namespaces to avoid naming conflicts.
-
-[^1]: For themes hosted on the [Hugo Themes Showcase](https://themes.gohugo.io/) components need to be added as git submodules that point to the directory `exampleSite/themes`
-
-
-
+[^1]: For themes hosted on the [Hugo Themes Showcase](https://themes.gohugo.io/) components need to be added as git submodules that point to the directory `exampleSite/themes`
diff --git a/content/en/hugo-modules/use-modules.md b/content/en/hugo-modules/use-modules.md
index 038e0bf89..8870307b3 100644
--- a/content/en/hugo-modules/use-modules.md
+++ b/content/en/hugo-modules/use-modules.md
@@ -20,8 +20,6 @@ toc: true
{{< gomodules-info >}}
-
-
## Initialize a New Module
Use `hugo mod init` to initialize a new Hugo Module. If it fails to guess the module path, you must provide it as an argument, e.g.:
@@ -33,6 +31,7 @@ hugo mod init github.com/gohugoio/myShortcodes
Also see the [CLI Doc](/commands/hugo_mod_init/).
## Use a Module for a Theme
+
The easiest way to use a Module for a theme is to import it in the config.
1. Initialize the hugo module system: `hugo mod init github.com/<your_user>/<your_project>`
@@ -60,8 +59,6 @@ hugo mod get -u
### Update All Modules Recursively
-{{< new-in "0.65.0" >}}
-
```bash
hugo mod get -u ./...
```
@@ -71,6 +68,7 @@ hugo mod get -u ./...
```bash
hugo mod get -u github.com/gohugoio/myShortcodes
```
+
### Get a Specific Version
```bash
@@ -89,16 +87,15 @@ replace github.com/bep/hugotestmods/mypartials => /Users/bep/hugotestmods/mypart
If you have the `hugo server` running, the configuration will be reloaded and `/Users/bep/hugotestmods/mypartials` put on the watch list.
-Note that since v.0.77.0 you can use modules config [`replacements`](https://gohugo.io/hugo-modules/configuration/#module-config-top-level) option. {{< new-in "0.77.0" >}}
+Instead of modifying the `go.mod` files, you can also use the modules config [`replacements`](https://gohugo.io/hugo-modules/configuration/#module-config-top-level) option.
## Print Dependency Graph
-
Use `hugo mod graph` from the relevant module directory and it will print the dependency graph, including vendoring, module replacement or disabled status.
E.g.:
-```
+```txt
hugo mod graph
github.com/bep/my-modular-site github.com/bep/hugotestmods/[email protected]
@@ -121,11 +118,10 @@ Note that:
* You can run `hugo mod vendor` on any level in the module tree.
* Vendoring will not store modules stored in your `themes` folder.
-* Most commands accept a `--ignoreVendorPaths` flag, which will then not use the vendored modules in `_vendor` for the module paths matching the [Glob](https://github.com/gobwas/glob) pattern given. Note that before Hugo 0.75 this flag was named `--ignoreVendor` and was a "all or nothing". {{< new-in "0.75.0" >}}
+* Most commands accept a `--ignoreVendorPaths` flag, which will then not use the vendored modules in `_vendor` for the module paths matching the [Glob](https://github.com/gobwas/glob) pattern given.
Also see the [CLI Doc](/commands/hugo_mod_vendor/).
-
## Tidy go.mod, go.sum
Run `hugo mod tidy` to remove unused entries in `go.mod` and `go.sum`.
@@ -138,6 +134,4 @@ Run `hugo mod clean` to delete the entire modules cache.
Note that you can also configure the `modules` cache with a `maxAge`, see [File Caches](/getting-started/configuration/#configure-file-caches).
-
-
Also see the [CLI Doc](/commands/hugo_mod_clean/).
diff --git a/content/en/hugo-pipes/_index.md b/content/en/hugo-pipes/_index.md
index 47411072a..078e1f186 100755
--- a/content/en/hugo-pipes/_index.md
+++ b/content/en/hugo-pipes/_index.md
@@ -2,7 +2,6 @@
title: Hugo Pipes Overview
date: 2018-07-14
publishdate: 2018-07-14
-lastmod: 2018-07-14
categories: [asset management]
keywords: []
menu:
@@ -11,5 +10,4 @@ menu:
weight: 10
weight: 10
sections_weight: 10
-draft: false
--- \ No newline at end of file
diff --git a/content/en/hugo-pipes/babel.md b/content/en/hugo-pipes/babel.md
index 7cf931f65..48db15c8d 100755
--- a/content/en/hugo-pipes/babel.md
+++ b/content/en/hugo-pipes/babel.md
@@ -3,7 +3,6 @@ title: Babel
description: Hugo Pipes can process JS files with Babel.
date: 2019-03-21
publishdate: 2019-03-21
-lastmod: 2019-03-21
categories: [asset management]
keywords: []
menu:
@@ -12,7 +11,6 @@ menu:
weight: 48
weight: 48
sections_weight: 48
-draft: false
---
Any JavaScript resource file can be transpiled to another JavaScript version using `resources.Babel` which takes for argument the resource object and an optional dict of options listed below. Babel uses the [babel cli](https://babeljs.io/docs/en/babel-cli).
@@ -24,37 +22,32 @@ Hugo Pipe's Babel requires the `@babel/cli` and `@babel/core` JavaScript package
If you are using the Hugo Snap package, Babel and plugin(s) need to be installed locally within your Hugo site directory, e.g., `npm install @babel/cli @babel/core --save-dev` without the `-g` flag.
{{% /note %}}
-
### Config
-{{< new-in "v0.75.0" >}}
-
-In Hugo `v0.75` we improved the way we resolve JS configuration and dependencies. One of them is that we now add the main project's `node_modules` to `NODE_PATH` when running Babel and similar tools. There are some known [issues](https://github.com/babel/babel/issues/5618) with Babel in this area, so if you have a `babel.config.js` living in a Hugo Module (and not in the project itself), we recommend using `require` to load the presets/plugins, e.g.:
+We add the main project's `node_modules` to `NODE_PATH` when running Babel and similar tools. There are some known [issues](https://github.com/babel/babel/issues/5618) with Babel in this area, so if you have a `babel.config.js` living in a Hugo Module (and not in the project itself), we recommend using `require` to load the presets/plugins, e.g.:
```js
module.exports = {
- presets: [
- [
- require('@babel/preset-env'),
- {
- useBuiltIns: 'entry',
- corejs: 3
- }
- ]
- ]
+ presets: [
+ [
+ require("@babel/preset-env"),
+ {
+ useBuiltIns: "entry",
+ corejs: 3,
+ },
+ ],
+ ],
};
```
-
-
### Options
config [string]
: Path to the Babel configuration file. Hugo will, by default, look for a `babel.config.js` in your project. More information on these configuration files can be found here: [babel configuration](https://babeljs.io/docs/en/configuration).
minified [bool]
-: Save as much bytes as possible when printing
+: Save as many bytes as possible when printing
noComments [bool]
: Write comments to generated output (true by default)
@@ -66,7 +59,7 @@ verbose [bool]
: Log everything
sourceMap [string]
-: Output `inline` or `external` sourcemap from the babel compile. External sourcemaps will be written to the target with the output file name + ".map". Input sourcemaps can be read from js.Build and node modules and combined into the output sourcemaps.
+: Output `inline` or `external` sourcemap from the babel compile. External sourcemaps will be written to the target with the output filename + ".map". Input sourcemaps can be read from js.Build and node modules and combined into the output sourcemaps.
### Examples
diff --git a/content/en/hugo-pipes/bundling.md b/content/en/hugo-pipes/bundling.md
index 79b866c93..227c7b1a3 100755
--- a/content/en/hugo-pipes/bundling.md
+++ b/content/en/hugo-pipes/bundling.md
@@ -12,7 +12,6 @@ menu:
weight: 60
weight: 60
sections_weight: 60
-draft: false
---
Asset files of the same MIME type can be bundled into one resource using `resources.Concat` which takes two arguments, a target path and a slice of resource objects.
diff --git a/content/en/hugo-pipes/fingerprint.md b/content/en/hugo-pipes/fingerprint.md
index b58b577db..f27ef7b55 100755
--- a/content/en/hugo-pipes/fingerprint.md
+++ b/content/en/hugo-pipes/fingerprint.md
@@ -3,7 +3,6 @@ title: Fingerprinting and SRI
description: Hugo Pipes allows Fingerprinting and Subresource Integrity.
date: 2018-07-14
publishdate: 2018-07-14
-lastmod: 2018-07-14
categories: [asset management]
keywords: []
menu:
@@ -12,10 +11,8 @@ menu:
weight: 70
weight: 70
sections_weight: 70
-draft: false
---
-
Fingerprinting and [SRI](https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity) can be applied to any asset file using `resources.Fingerprint` which takes two arguments, the resource object and a [hash function](https://en.wikipedia.org/wiki/Cryptographic_hash_function).
The default hash function is `sha256`. Other available functions are `sha384` (from Hugo `0.55`), `sha512` and `md5`.
@@ -25,5 +22,5 @@ Any so processed asset will bear a `.Data.Integrity` property containing an inte
```go-html-template
{{ $js := resources.Get "js/global.js" }}
{{ $secureJS := $js | resources.Fingerprint "sha512" }}
-<script type="text/javascript" src="{{ $secureJS.Permalink }}" integrity="{{ $secureJS.Data.Integrity }}"></script>
+<script src="{{ $secureJS.Permalink }}" integrity="{{ $secureJS.Data.Integrity }}"></script>
```
diff --git a/content/en/hugo-pipes/introduction.md b/content/en/hugo-pipes/introduction.md
index a3c956885..c16572e48 100755
--- a/content/en/hugo-pipes/introduction.md
+++ b/content/en/hugo-pipes/introduction.md
@@ -4,7 +4,6 @@ linkTitle: Hugo Pipes
description: Hugo Pipes is Hugo's asset processing set of functions.
date: 2018-07-14
publishdate: 2018-07-14
-lastmod: 2018-07-14
categories: [asset management]
keywords: []
menu:
@@ -31,10 +30,8 @@ Note that you can mount any directory into Hugo's virtual `assets` folder using
| `resources.GetMatch` | `GetMatch` finds the first Resource matching the given pattern, or nil if none found. See Match for a more complete explanation about the rules used. |
| `resources.Match` | `Match` gets all resources matching the given base path prefix, e.g "*.png" will match all png files. The "*" does not match path delimiters (/), so if you organize your resources in sub-folders, you need to be explicit about it, e.g.: "images/*.png". To match any PNG image anywhere in the bundle you can do "\*\*.png", and to match all PNG images below the images folder, use "images/\*\*.jpg". The matching is case insensitive. Match matches by using the files name with path relative to the file system root with Unix style slashes (/) and no leading slash, e.g. "images/logo.png". See https://github.com/gobwas/glob for the full rules set.|
-
See the [GoDoc Page](https://pkg.go.dev/github.com/gohugoio/[email protected]/tpl/resources) for the `resources` package for an up to date overview of all template functions in this namespace.
-
## Get Resource with resources.Get and resources.GetRemote
In order to process an asset with Hugo Pipes, it must be retrieved as a `Resource` using `resources.Get` or `resources.GetRemote`.
@@ -68,7 +65,6 @@ With `resources.GetRemote`, the first argument is a remote URL:
By default, Hugo calculates a cache key based on the `URL` and the `options` (e.g. headers) given.
-
{{< new-in "0.97.0" >}} You can override this by setting a `key` in the options map. This can be used to get more fine grained control over how often a remote resource is fetched, e.g.:
@@ -79,8 +75,6 @@ By default, Hugo calculates a cache key based on the `URL` and the `options` (e.
### Error Handling
-{{< new-in "0.91.0" >}}
-
The return value from `resources.GetRemote` includes an `.Err` method that will return an error if the call failed. If you want to just log any error as a `WARNING` you can use a construct similar to the one below.
```go-html-template
@@ -131,7 +125,7 @@ Asset files must be stored in the asset directory. This is `/assets` by default,
### Asset Publishing
-Hugo publishes assets to the to the `publishDir` (typically `public`) when you invoke `.Permalink`, `.RelPermalink`, or `.Publish`. You can use `.Content` to inline the asset.
+Hugo publishes assets to the `publishDir` (typically `public`) when you invoke `.Permalink`, `.RelPermalink`, or `.Publish`. You can use `.Content` to inline the asset.
## Go Pipes
@@ -156,7 +150,7 @@ The example above can therefore also be written as follows:
## Caching
-Hugo Pipes invocations are cached based on the entire _pipe chain_.
+Hugo Pipes invocations are cached based on the entire *pipe chain*.
An example of a pipe chain is:
diff --git a/content/en/hugo-pipes/js.md b/content/en/hugo-pipes/js.md
index ff29ca958..c95688e68 100644
--- a/content/en/hugo-pipes/js.md
+++ b/content/en/hugo-pipes/js.md
@@ -3,7 +3,6 @@ title: JavaScript Building
description: Hugo Pipes can process JavaScript files with [ESBuild](https://github.com/evanw/esbuild).
date: 2020-07-20
publishdate: 2020-07-20
-lastmod: 2020-07-20
categories: [asset management]
keywords: []
menu:
@@ -12,7 +11,6 @@ menu:
weight: 45
weight: 45
sections_weight: 45
-draft: false
---
Any JavaScript resource file can be transpiled and "tree shaken" using `js.Build` which takes for argument either a string for the filepath or a dict of options listed below.
@@ -20,33 +18,33 @@ Any JavaScript resource file can be transpiled and "tree shaken" using `js.Build
### Options
targetPath [string]
-: If not set, the source path will be used as the base target path.
+: If not set, the source path will be used as the base target path.
Note that the target path's extension may change if the target MIME type is different, e.g. when the source is TypeScript.
-params [map or slice] {{< new-in "0.78.0" >}}
+params [map or slice]
: Params that can be imported as JSON in your JS files, e.g.:
```go-html-template
{{ $js := resources.Get "js/main.js" | js.Build (dict "params" (dict "api" "https://example.org/api")) }}
```
-And then in your JS file:
+And then in your JS file:
```js
import * as params from '@params';
-```
+```
Note that this is meant for small data sets, e.g. config settings. For larger data, please put/mount the files into `/assets` and import them directly.
minify [bool]
: Let `js.Build` handle the minification.
-inject [slice] {{< new-in "0.81.0" >}}
+inject [slice]
: This option allows you to automatically replace a global variable with an import from another file. The path names must be relative to `assets`. See https://esbuild.github.io/api/#inject
-shims {{< new-in "0.81.0" >}}
+shims
: This option allows swapping out a component with another. A common use case is to load dependencies like React from a CDN (with _shims_) when in production, but running with the full bundled `node_modules` dependency during development:
-```
+```go-html-template
{{ $shims := dict "react" "js/shims/react.js" "react-dom" "js/shims/react-dom.js" }}
{{ $js = $js | js.Build dict "shims" $shims }}
```
@@ -63,17 +61,12 @@ module.exports = window.React;
module.exports = window.ReactDOM;
```
-
With the above, these imports should work in both scenarios:
```js
import * as React from 'react'
import * as ReactDOM from 'react-dom';
```
-sourceMap [string, bool] {{< new-in "0.75.0" >}}
-: Let `js.Build` output sourceMap. Current only inline is supported. true defaults to inline.
- One of: '`inline`, `external`
- Default is "" (disabled)
target [string]
: The language target.
@@ -91,19 +84,17 @@ defines [map]
{{ $defines := dict "process.env.NODE_ENV" `"development"` }}
```
-format [string] {{< new-in "0.74.3" >}}
+format [string]
: The output format.
One of: `iife`, `cjs`, `esm`.
Default is `iife`, a self-executing function, suitable for inclusion as a <script> tag.
sourceMap
-: Whether to generate `inline` or `external` sourcemap from esbuild. External sourcemaps will be written to the target with the output file name + ".map". Input sourcemaps can be read from js.Build and node modules and combined into the output sourcemaps.
+: Whether to generate `inline` or `external` sourcemap from esbuild. External sourcemaps will be written to the target with the output filename + ".map". Input sourcemaps can be read from js.Build and node modules and combined into the output sourcemaps.
### Import JS code from /assets
-{{< new-in "0.78.0" >}}
-
-Since Hugo `v0.78.0` `js.Build` has full support for the virtual union file system in [Hugo Modules](/hugo-modules/). You can see some simple examples in this [test project](https://github.com/gohugoio/hugoTestProjectJSModImports), but in short this means that you can do this:
+`js.Build` has full support for the virtual union file system in [Hugo Modules](/hugo-modules/). You can see some simple examples in this [test project](https://github.com/gohugoio/hugoTestProjectJSModImports), but in short this means that you can do this:
```js
import { hello } from 'my/module';
@@ -129,14 +120,14 @@ For other files (e.g. `JSON`, `CSS`) you need to use the relative path including
import * as data from 'my/module/data.json';
```
-Any imports in a file outside `/assets` or that does not resolve to a component inside `/assets` will be resolved by [ESBuild](https://esbuild.github.io/) with the **project directory** as the resolve directory (used as the starting point when looking for `node_modules` etc.). Also see [hugo mod npm pack](/commands/hugo_mod_npm_pack/). If you have any imported NPM dependencies in your project, you need to make sure to run `npm install` before you run `hugo`.
+Any imports in a file outside `/assets` or that does not resolve to a component inside `/assets` will be resolved by [ESBuild](https://esbuild.github.io/) with the **project directory** as the resolve directory (used as the starting point when looking for `node_modules` etc.). Also see [hugo mod npm pack](/commands/hugo_mod_npm_pack/). If you have any imported npm dependencies in your project, you need to make sure to run `npm install` before you run `hugo`.
Also note the new `params` option that can be passed from template to your JS files, e.g.:
```go-html-template
{{ $js := resources.Get "js/main.js" | js.Build (dict "params" (dict "api" "https://example.org/api")) }}
```
-And then in your JS file:
+And then in your JS file:
```js
import * as params from '@params';
@@ -145,14 +136,13 @@ import * as params from '@params';
Hugo will, by default, generate a `assets/jsconfig.json` file that maps the imports. This is useful for navigation/intellisense help inside code editors, but if you don't need/want it, you can [turn it off](/getting-started/configuration/#configure-build).
-
### Include Dependencies In package.json / node_modules
-Any imports in a file outside `/assets` or that does not resolve to a component inside `/assets` will be resolved by [ESBuild](https://esbuild.github.io/) with the **project directory** as the resolve directory (used as the starting point when looking for `node_modules` etc.). Also see [hugo mod npm pack](/commands/hugo_mod_npm_pack/). If you have any imported NPM dependencies in your project, you need to make sure to run `npm install` before you run `hugo`.
+Any imports in a file outside `/assets` or that does not resolve to a component inside `/assets` will be resolved by [ESBuild](https://esbuild.github.io/) with the **project directory** as the resolve directory (used as the starting point when looking for `node_modules` etc.). Also see [hugo mod npm pack](/commands/hugo_mod_npm_pack/). If you have any imported npm dependencies in your project, you need to make sure to run `npm install` before you run `hugo`.
-{{< new-in "0.78.1" >}} From Hugo `0.78.1` the start directory for resolving NPM packages (aka. packages that live inside a `node_modules` folder) is always the main project folder.
+The start directory for resolving npm packages (aka. packages that live inside a `node_modules` folder) is always the main project folder.
-**Note:** If you're developing a theme/component that is supposed to be imported and depends on dependencies inside `package.json`, we recommend reading about [hugo mod npm pack](/commands/hugo_mod_npm_pack/), a tool to consolidate all the NPM dependencies in a project.
+**Note:** If you're developing a theme/component that is supposed to be imported and depends on dependencies inside `package.json`, we recommend reading about [hugo mod npm pack](/commands/hugo_mod_npm_pack/), a tool to consolidate all the npm dependencies in a project.
### Examples
@@ -169,7 +159,5 @@ Or with options:
{{ $opts := dict "targetPath" "main.js" "externals" $externals "defines" $defines }}
{{ $built := resources.Get "scripts/main.js" | js.Build $opts }}
-<script type="text/javascript" src="{{ $built.RelPermalink }}" defer></script>
+<script src="{{ $built.RelPermalink }}" defer></script>
```
-
-
diff --git a/content/en/hugo-pipes/minification.md b/content/en/hugo-pipes/minification.md
index d11ee58a9..6e539e0e7 100755
--- a/content/en/hugo-pipes/minification.md
+++ b/content/en/hugo-pipes/minification.md
@@ -3,7 +3,6 @@ title: Asset minification
description: Hugo Pipes allows the minification of any CSS, JS, JSON, HTML, SVG or XML resource.
date: 2018-07-14
publishdate: 2018-07-14
-lastmod: 2018-07-14
categories: [asset management]
keywords: []
menu:
@@ -12,13 +11,10 @@ menu:
weight: 50
weight: 50
sections_weight: 50
-draft: false
---
-
Any resource of the aforementioned types can be minified using `resources.Minify` which takes for argument the resource object.
-
```go-html-template
{{ $css := resources.Get "css/main.css" }}
{{ $style := $css | resources.Minify }}
diff --git a/content/en/hugo-pipes/postcss.md b/content/en/hugo-pipes/postcss.md
index 46833e0a4..b87dc4595 100755
--- a/content/en/hugo-pipes/postcss.md
+++ b/content/en/hugo-pipes/postcss.md
@@ -3,7 +3,6 @@ title: PostCSS
description: Hugo Pipes can process CSS files with PostCSS.
date: 2018-07-14
publishdate: 2018-07-14
-lastmod: 2018-07-14
categories: [asset management]
keywords: []
menu:
@@ -12,10 +11,9 @@ menu:
weight: 40
weight: 40
sections_weight: 40
-draft: false
---
-Any asset file can be processed using `resources.PostCSS` which takes for argument the resource object and a slice of options listed below.
+Any asset file can be processed using `resources.PostCSS` which takes for argument the resource object and a slice of options listed below.
The resource will be processed using the project's or theme's own `postcss.config.js` or any file set with the `config` option.
@@ -38,15 +36,14 @@ config [string]
noMap [bool]
: Default is `false`. Disable the default inline sourcemaps
-inlineImports [bool] {{< new-in "0.66.0" >}}
+inlineImports [bool]
: Default is `false`. Enable inlining of @import statements. It does so recursively, but will only import a file once.
URL imports (e.g. `@import url('https://fonts.googleapis.com/css?family=Open+Sans&display=swap');`) and imports with media queries will be ignored.
Note that this import routine does not care about the CSS spec, so you can have @import anywhere in the file.
Hugo will look for imports relative to the module mount and will respect theme overrides.
skipInlineImportsNotFound [bool] {{< new-in "0.99.0" >}}
-
-Before Hugo 0.99.0 when `inlineImports` was enabled and we failed to resolve an import, we logged it as a warning. We now fail the build. If you have regular CSS imports in your CSS that you want to preserve, you can either use imports with URL or media queries (Hugo does not try to resolve those) or set `skipInlineImportsNotFound` to true.
+: Default is `false`. Before Hugo 0.99.0 when `inlineImports` was enabled and we failed to resolve an import, we logged it as a warning. We now fail the build. If you have regular CSS imports in your CSS that you want to preserve, you can either use imports with URL or media queries (Hugo does not try to resolve those) or set `skipInlineImportsNotFound` to true.
_If no configuration file is used:_
@@ -72,8 +69,6 @@ syntax [string]
## Check Hugo Environment from postcss.config.js
-{{< new-in "0.66.0" >}}
-
The current Hugo environment name (set by `--environment` or in config or OS environment) is available in the Node context, which allows constructs like this:
```js
diff --git a/content/en/hugo-pipes/postprocess.md b/content/en/hugo-pipes/postprocess.md
index aafb786a4..1aa398356 100755
--- a/content/en/hugo-pipes/postprocess.md
+++ b/content/en/hugo-pipes/postprocess.md
@@ -12,7 +12,7 @@ weight: 39
sections_weight: 39
---
-Marking a resource with `resources.PostProcess` delays any transformations to after the build, typically because one or more of the steps in the transformation chain depends on the result of the build (e.g. files in `public`).{{< new-in "0.69.0" >}}
+Marking a resource with `resources.PostProcess` delays any transformations to after the build, typically because one or more of the steps in the transformation chain depends on the result of the build (e.g. files in `public`).
A prime use case for this is [CSS purging with PostCSS](#css-purging-with-postcss).
diff --git a/content/en/hugo-pipes/resource-from-string.md b/content/en/hugo-pipes/resource-from-string.md
index 8b942d2f3..ae7598ebe 100755
--- a/content/en/hugo-pipes/resource-from-string.md
+++ b/content/en/hugo-pipes/resource-from-string.md
@@ -4,7 +4,6 @@ linkTitle: Resource from String
description: Hugo Pipes allows the creation of a resource from a string.
date: 2018-07-14
publishdate: 2018-07-14
-lastmod: 2018-07-14
categories: [asset management]
keywords: []
menu:
@@ -13,7 +12,6 @@ menu:
weight: 90
weight: 90
sections_weight: 90
-draft: false
---
It is possible to create a resource directly from the template using `resources.FromString` which takes two arguments, the given string and the resource target path.
@@ -26,6 +24,6 @@ The following example creates a resource file containing localized variables for
{{ $vars := $string | resources.FromString $targetPath }}
{{ $global := resources.Get "js/global.js" | resources.Minify }}
-<script type="text/javascript" src="{{ $vars.Permalink }}"></script>
-<script type="text/javascript" src="{{ $global.Permalink }}"></script>
+<script src="{{ $vars.Permalink }}"></script>
+<script src="{{ $global.Permalink }}"></script>
```
diff --git a/content/en/hugo-pipes/resource-from-template.md b/content/en/hugo-pipes/resource-from-template.md
index 9bc8c7e9d..bb0fdb2c2 100755
--- a/content/en/hugo-pipes/resource-from-template.md
+++ b/content/en/hugo-pipes/resource-from-template.md
@@ -4,7 +4,6 @@ linkTitle: Resource from Template
description: Hugo Pipes allows the creation of a resource from an asset file using Go Template.
date: 2018-07-14
publishdate: 2018-07-14
-lastmod: 2018-07-14
categories: [asset management]
keywords: []
menu:
@@ -13,7 +12,6 @@ menu:
weight: 80
weight: 80
sections_weight: 80
-draft: false
---
In order to use Hugo Pipes function on an asset file containing Go Template magic the function `resources.ExecuteAsTemplate` must be used.
@@ -25,13 +23,12 @@ The function takes three arguments: the resource target path, the template conte
$backgroundColor: {{ .Param "backgroundColor" }};
$textColor: {{ .Param "textColor" }};
body{
- background-color:$backgroundColor;
- color: $textColor;
+ background-color:$backgroundColor;
+ color: $textColor;
}
// [...]
```
-
```go-html-template
{{ $sassTemplate := resources.Get "sass/template.scss" }}
{{ $style := $sassTemplate | resources.ExecuteAsTemplate "main.scss" . | resources.ToCSS }}
diff --git a/content/en/hugo-pipes/scss-sass.md b/content/en/hugo-pipes/scss-sass.md
index c4a0a5520..ad4a66b11 100755
--- a/content/en/hugo-pipes/scss-sass.md
+++ b/content/en/hugo-pipes/scss-sass.md
@@ -1,9 +1,8 @@
---
-title: SASS / SCSS
-description: Hugo Pipes allows the processing of SASS and SCSS files.
+title: Sass / SCSS
+description: Hugo Pipes allows the processing of Sass and SCSS files.
date: 2018-07-14
publishdate: 2018-07-14
-lastmod: 2018-07-14
categories: [asset management]
keywords: []
menu:
@@ -12,11 +11,9 @@ menu:
weight: 30
weight: 02
sections_weight: 02
-draft: false
---
-
-Any SASS or SCSS file can be transformed into a CSS file using `resources.ToCSS` which takes two arguments, the resource object and a map of options listed below.
+Any Sass or SCSS file can be transformed into a CSS file using `resources.ToCSS` which takes two arguments, the resource object and a map of options listed below.
```go-html-template
{{ $sass := resources.Get "sass/main.scss" }}
@@ -25,9 +22,9 @@ Any SASS or SCSS file can be transformed into a CSS file using `resources.ToCSS`
### Options
-transpiler [string] {{< new-in "0.80.0" >}}
+transpiler [string]
-: The `transpiler` to use, valid values are `libsass` (default) and `dartsass`. Note that the Embedded Dart Sass project is still in beta. We will try to improve the installation process when it has stable releases, but if you want to use Hugo with Dart Sass you need to download a release binary from [Embedded Dart Sass](https://github.com/sass/dart-sass-embedded/releases) (Hugo after 0.81.0 requires beta 6 or newer) and make sure it's in your PC's `$PATH` (or `%PATH%` on Windows).
+: The `transpiler` to use, valid values are `libsass` (default) and `dartsass`. If you want to use Hugo with Dart Sass you need to download a release binary from [Embedded Dart Sass](https://github.com/sass/dart-sass-embedded/releases) and make sure it's in your PC's `$PATH` (or `%PATH%` on Windows).
targetPath [string]
: If not set, the resource's target path will be the asset file original path with its extension replaced by `.css`.
@@ -42,7 +39,7 @@ enableSourceMap [bool]
: When enabled, a source map will be generated.
includePaths [string slice]
-: Additional SCSS/SASS include paths. Paths must be relative to the project directory.
+: Additional SCSS/Sass include paths. Paths must be relative to the project directory.
```go-html-template
{{ $options := (dict "targetPath" "style.css" "outputStyle" "compressed" "enableSourceMap" (not hugo.IsProduction) "includePaths" (slice "node_modules/myscss")) }}
@@ -50,5 +47,5 @@ includePaths [string slice]
```
{{% note %}}
-Setting `outputStyle` to `compressed` will handle SASS/SCSS files minification better than the more generic [`resources.Minify`]({{< ref "minification">}}).
+Setting `outputStyle` to `compressed` will handle Sass/SCSS files minification better than the more generic [`resources.Minify`]({{< ref "minification">}}).
{{% /note %}}
diff --git a/content/en/installation/_index.md b/content/en/installation/_index.md
new file mode 100644
index 000000000..e5a34b1f2
--- /dev/null
+++ b/content/en/installation/_index.md
@@ -0,0 +1,15 @@
+---
+title: Installation
+linkTitle: Installation overview
+description: Install Hugo on macOS, Linux, Windows, BSD, and on any machine that can run the Go compiler tool chain.
+aliases: [/getting-started/installing/]
+categories: [installation]
+keywords: [installation]
+menu:
+ docs:
+ parent: installation
+ weight: 10
+toc: false
+---
+
+{{% param "description" %}}
diff --git a/content/en/installation/bsd.md b/content/en/installation/bsd.md
new file mode 100644
index 000000000..f17b64085
--- /dev/null
+++ b/content/en/installation/bsd.md
@@ -0,0 +1,79 @@
+---
+title: BSD
+linkTitle: BSD
+description: Install Hugo on BSD derivatives.
+categories: [installation]
+menu:
+ docs:
+ parent: installation
+ weight: 50
+toc: true
+weight: 50
+---
+{{% readfile file="/installation/common/01-editions.md" %}}
+
+{{% readfile file="/installation/common/02-prerequisites.md" %}}
+
+{{% readfile file="/installation/common/03-prebuilt-binaries.md" %}}
+
+## Repository packages
+
+Most BSD derivatives maintain a repository for commonly installed applications. Please note that these repositories may not contain the [latest release].
+
+[latest release]: https://github.com/gohugoio/hugo/releases/latest
+
+### DragonFly BSD
+
+[DragonFly BSD] includes Hugo in its package repository. This will install the extended edition of Hugo:
+
+```sh
+sudo pkg install gohugo
+```
+
+[DragonFly BSD]: https://www.dragonflybsd.org/
+
+### FreeBSD
+
+[FreeBSD] includes Hugo in its package repository. This will install the extended edition of Hugo:
+
+```sh
+sudo pkg install gohugo
+```
+
+[FreeBSD]: https://www.freebsd.org/
+
+### NetBSD
+
+[NetBSD] includes Hugo in its package repository. This will install the extended edition of Hugo:
+
+```sh
+sudo pkgin install go-hugo
+```
+
+[NetBSD]: https://www.netbsd.org/
+
+### OpenBSD
+
+[OpenBSD] includes Hugo in its package repository. This will prompt you to select which edition of Hugo to install:
+
+```sh
+doas pkg_add hugo
+```
+
+[OpenBSD]: https://www.openbsd.org/
+
+{{% readfile file="/installation/common/04-docker.md" %}}
+
+{{% readfile file="/installation/common/05-build-from-source.md" %}}
+
+## Comparison
+
+||Prebuilt binaries|Repository packages|Docker|Build from source
+:--|:--:|:--:|:--:|:--:
+Easy to install?|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|
+Easy to upgrade?|:heavy_check_mark:|varies|:heavy_check_mark:|:heavy_check_mark:
+Easy to downgrade?|:heavy_check_mark:|varies|:heavy_check_mark:|:heavy_check_mark:
+Automatic updates?|:x:|varies|:x: [^1]|:x:
+Latest version available?|:heavy_check_mark:|varies|:heavy_check_mark:|:heavy_check_mark:
+
+[^1]: Possible but requires advanced configuration.
diff --git a/content/en/installation/common/01-editions.md b/content/en/installation/common/01-editions.md
new file mode 100644
index 000000000..ee9f3ff93
--- /dev/null
+++ b/content/en/installation/common/01-editions.md
@@ -0,0 +1,8 @@
+## Editions
+
+Hugo is available in two editions: standard and extended. With the extended edition you can:
+
+- Encode WebP images (you can decode WebP images with both editions)
+- Transpile Sass to CSS using the embedded LibSass transpiler
+
+We recommend that you install the extended edition.
diff --git a/content/en/installation/common/02-prerequisites.md b/content/en/installation/common/02-prerequisites.md
new file mode 100644
index 000000000..008370825
--- /dev/null
+++ b/content/en/installation/common/02-prerequisites.md
@@ -0,0 +1,27 @@
+## Prerequisites
+
+Although not required in all cases, Git and Go are often used when working with Hugo.
+
+Git is required to:
+
+- Use the [Hugo Modules] feature
+- Build Hugo from source
+- Install a theme as a Git submodule
+- Access [commit information] from a local Git repository
+- Host your site with services such as [AWS Amplify], [CloudCannon], [Cloudflare Pages], [GitHub Pages], [GitLab Pages], and [Netlify].
+
+Go is required to:
+
+- Use the Hugo Modules feature
+- Build Hugo from source
+
+Please refer to the [Git] and [Go] documentation for installation instructions.
+
+[AWS Amplify]: https://aws.amazon.com/amplify/
+[CloudCannon]: https://cloudcannon.com/
+[Cloudflare Pages]: https://pages.cloudflare.com/
+[Git]: https://git-scm.com/book/en/v2/Getting-Started-Installing-Git
+[GitHub Pages]: https://pages.github.com/
+[GitLab Pages]: https://docs.gitlab.com/ee/user/project/pages/
+[Go]: https://go.dev/doc/install
+[Netlify]: https://www.netlify.com/
diff --git a/content/en/installation/common/03-prebuilt-binaries.md b/content/en/installation/common/03-prebuilt-binaries.md
new file mode 100644
index 000000000..f821f79a2
--- /dev/null
+++ b/content/en/installation/common/03-prebuilt-binaries.md
@@ -0,0 +1,21 @@
+## Prebuilt binaries
+
+Prebuilt binaries are available for a variety of operating systems and architectures. Visit the [latest release] page, and scroll down to the Assets section.
+
+<!-- markdownlint-disable-next-line MD051 -->
+1. Download the archive for the desired [edition], operating system, and architecture
+1. Extract the archive
+1. Move the executable to the desired directory
+1. Add this directory to the PATH environment variable
+1. Verify that you have _execute_ permission on the file
+
+Please consult your operating system documentation if you need help setting file permissions or modifying your PATH environment variable.
+
+If you do not see a prebuilt binary for the desired edition, operating system, and architecture, install Hugo using one of the methods described below.
+
+[commit information]: https://gohugo.io/variables/git
+[edition]: #editions
+[Git]: https://git-scm.com/
+[Go]: https://go.dev/
+[Hugo Modules]: /hugo-modules/
+[latest release]: https://github.com/gohugoio/hugo/releases/latest
diff --git a/content/en/installation/common/04-docker.md b/content/en/installation/common/04-docker.md
new file mode 100644
index 000000000..24f5cd942
--- /dev/null
+++ b/content/en/installation/common/04-docker.md
@@ -0,0 +1,10 @@
+## Docker
+
+[Erlend Klakegg Bergheim] graciously maintains [Docker images] based on images for Alpine Linux, Busybox, Debian, and Ubuntu.
+
+```sh
+docker pull klakegg/hugo
+```
+
+[Docker images]: https://hub.docker.com/r/klakegg/hugo
+[Erlend Klakegg Bergheim]: https://github.com/klakegg
diff --git a/content/en/installation/common/05-build-from-source.md b/content/en/installation/common/05-build-from-source.md
new file mode 100644
index 000000000..a135de9fd
--- /dev/null
+++ b/content/en/installation/common/05-build-from-source.md
@@ -0,0 +1,20 @@
+## Build from source
+
+To build Hugo from source you must:
+
+1. Install [Git]
+1. Install [Go] version 1.18 or later
+1. Update your PATH environment variable as described in the [Go documentation]
+
+> The install directory is controlled by the GOPATH and GOBIN environment variables. If GOBIN is set, binaries are installed to that directory. If GOPATH is set, binaries are installed to the bin subdirectory of the first directory in the GOPATH list. Otherwise, binaries are installed to the bin subdirectory of the default GOPATH ($HOME/go or %USERPROFILE%\go).
+
+Then build and test:
+
+```sh
+go install -tags extended github.com/gohugoio/hugo@latest
+hugo version
+```
+
+[Git]: https://git-scm.com/book/en/v2/Getting-Started-Installing-Git
+[Go]: https://go.dev/doc/install
+[Go documentation]: https://go.dev/doc/code#Command
diff --git a/content/en/installation/common/homebrew.md b/content/en/installation/common/homebrew.md
new file mode 100644
index 000000000..7178a9f4f
--- /dev/null
+++ b/content/en/installation/common/homebrew.md
@@ -0,0 +1,9 @@
+### Homebrew
+
+[Homebrew] is a free and open source package manager for macOS and Linux. This will install the extended edition of Hugo:
+
+```sh
+brew install hugo
+```
+
+[Homebrew]: https://brew.sh/
diff --git a/content/en/installation/common/index.md b/content/en/installation/common/index.md
new file mode 100644
index 000000000..cbb7365a6
--- /dev/null
+++ b/content/en/installation/common/index.md
@@ -0,0 +1,3 @@
++++
+headless = true
++++
diff --git a/content/en/installation/linux.md b/content/en/installation/linux.md
new file mode 100644
index 000000000..03ffe9430
--- /dev/null
+++ b/content/en/installation/linux.md
@@ -0,0 +1,125 @@
+---
+title: Linux
+linkTitle: Linux
+description: Install Hugo on Linux.
+categories: [installation]
+menu:
+ docs:
+ parent: installation
+ weight: 30
+toc: true
+weight: 30
+---
+{{% readfile file="/installation/common/01-editions.md" %}}
+
+{{% readfile file="/installation/common/02-prerequisites.md" %}}
+
+{{% readfile file="/installation/common/03-prebuilt-binaries.md" %}}
+
+## Package managers
+
+### Snap
+
+[Snap] is a free and open source package manager for Linux. Available for [most distributions], Snap packages are simple to install and are automatically updated. This will install the extended edition of Hugo:
+
+```sh
+sudo snap install hugo
+```
+
+[most distributions]: https://snapcraft.io/docs/installing-snapd
+[Snap]: https://snapcraft.io/
+
+{{% readfile file="/installation/common/homebrew.md" %}}
+
+## Repository packages
+
+Most Linux distributions maintain a repository for commonly installed applications. Please note that these repositories may not contain the [latest release].
+
+[latest release]: https://github.com/gohugoio/hugo/releases/latest
+
+### Arch Linux
+
+Derivatives of the [Arch Linux] distribution of Linux include [EndeavourOS], [Garuda Linux], [Manjaro], and others. This will install the extended edition of Hugo:
+
+```sh
+sudo pacman -S hugo
+```
+
+[Arch Linux]: https://archlinux.org/
+[EndeavourOS]: https://endeavouros.com/
+[Manjaro]: https://manjaro.org/
+[Garuda Linux]: https://garudalinux.org/
+
+### Debian
+
+Derivatives of the [Debian] distribution of Linux include [elementary OS], [KDE neon], [Linux Lite], [Linux Mint], [MX Linux], [Pop!_OS], [Ubuntu], [Zorin OS], and others. This will install the extended edition of Hugo:
+
+```sh
+sudo apt install hugo
+```
+
+You can also download Debian packages from the [latest release] page.
+
+[Debian]: https://www.debian.org/
+[elementary OS]: https://elementary.io/
+[KDE neon]: https://neon.kde.org/
+[Linux Lite]: https://www.linuxliteos.com/
+[Linux Mint]: https://linuxmint.com/
+[MX Linux]: https://mxlinux.org/
+[Pop!_OS]: https://pop.system76.com/
+[Ubuntu]: https://ubuntu.com/
+[Zorin OS]: https://zorin.com/os/
+
+### Fedora
+
+Derivatives of the [Fedora] distribution of Linux include [CentOS], [Red Hat Enterprise Linux], and others. This will install the extended edition of Hugo:
+
+
+```sh
+sudo dnf install hugo
+```
+
+[CentOS]: https://www.centos.org/
+[Fedora]: https://getfedora.org/
+[Red Hat Enterprise Linux]: https://www.redhat.com/
+
+### openSUSE
+
+Derivatives of the [openSUSE] distribution of Linux include [GeckoLinux], [Linux Karmada], and others. This will install the extended edition of Hugo:
+
+
+```sh
+sudo zypper install hugo
+```
+
+[GeckoLinux]: https://geckolinux.github.io/
+[Linux Karmada]: https://linuxkamarada.com/
+[openSUSE]: https://www.opensuse.org/
+
+### Solus
+
+The [Solus] distribution of Linux includes Hugo in its package repository. This will install the _standard_ edition of Hugo:
+
+```sh
+sudo eopkg install hugo
+```
+
+[Solus]: https://getsol.us/home/
+
+{{% readfile file="/installation/common/04-docker.md" %}}
+
+{{% readfile file="/installation/common/05-build-from-source.md" %}}
+
+## Comparison
+
+||Prebuilt binaries|Package managers|Repository packages|Docker|Build from source
+:--|:--:|:--:|:--:|:--:|:--:
+Easy to install?|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:
+Easy to upgrade?|:heavy_check_mark:|:heavy_check_mark:|varies|:heavy_check_mark:|:heavy_check_mark:
+Easy to downgrade?|:heavy_check_mark:|:heavy_check_mark: [^1]|varies|:heavy_check_mark:|:heavy_check_mark:
+Automatic updates?|:x:|varies [^2]|:x:|:x: [^3]|:x:
+Latest version available?|:heavy_check_mark:|:heavy_check_mark:|varies|:heavy_check_mark:|:heavy_check_mark:
+
+[^1]: Easy if a previous version is still installed.
+[^2]: Snap packages are automatically updated. Homebrew requires advanced configuration.
+[^3]: Possible but requires advanced configuration.
diff --git a/content/en/installation/macos.md b/content/en/installation/macos.md
new file mode 100644
index 000000000..c614f39ba
--- /dev/null
+++ b/content/en/installation/macos.md
@@ -0,0 +1,48 @@
+---
+title: macOS
+linkTitle: macOS
+description: Install Hugo on macOS.
+categories: [installation]
+menu:
+ docs:
+ parent: installation
+ weight: 20
+toc: true
+weight: 20
+---
+{{% readfile file="/installation/common/01-editions.md" %}}
+
+{{% readfile file="/installation/common/02-prerequisites.md" %}}
+
+{{% readfile file="/installation/common/03-prebuilt-binaries.md" %}}
+
+## Package managers
+
+{{% readfile file="/installation/common/homebrew.md" %}}
+
+### MacPorts
+
+[MacPorts] is a free and open source package manager for macOS. This will install the extended edition of Hugo:
+
+```sh
+sudo port install hugo
+```
+
+[MacPorts]: https://www.macports.org/
+
+{{% readfile file="/installation/common/04-docker.md" %}}
+
+{{% readfile file="/installation/common/05-build-from-source.md" %}}
+
+## Comparison
+
+||Prebuilt binaries|Package managers|Docker|Build from source
+:--|:--:|:--:|:--:|:--:|:--:
+Easy to install?|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|
+Easy to upgrade?|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:
+Easy to downgrade?|:heavy_check_mark:|:heavy_check_mark: [^1]|:heavy_check_mark:|:heavy_check_mark:
+Automatic updates?|:x:|:x: [^2]|:x: [^2]|:x:
+Latest version available?|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:
+
+[^1]: Easy if a previous version is still installed.
+[^2]: Possible but requires advanced configuration.
diff --git a/content/en/installation/windows.md b/content/en/installation/windows.md
new file mode 100644
index 000000000..6ef17acd4
--- /dev/null
+++ b/content/en/installation/windows.md
@@ -0,0 +1,63 @@
+---
+title: Windows
+linkTitle: Windows
+description: Install Hugo on Windows.
+categories: [installation]
+menu:
+ docs:
+ parent: installation
+ weight: 40
+toc: true
+weight: 40
+---
+{{% readfile file="/installation/common/01-editions.md" %}}
+
+{{% readfile file="/installation/common/02-prerequisites.md" %}}
+
+{{% readfile file="/installation/common/03-prebuilt-binaries.md" %}}
+
+## Package managers
+
+### Chocolatey
+
+[Chocolatey] is a free and open source package manager for Windows. This will install the extended edition of Hugo:
+
+```sh
+choco install hugo-extended
+```
+
+[Chocolatey]: https://chocolatey.org/
+
+### Scoop
+
+[Scoop] is a free and open source package manager for Windows. This will install the extended edition of Hugo:
+
+```sh
+scoop install hugo-extended
+```
+
+[Scoop]: https://scoop.sh/
+
+{{% readfile file="/installation/common/04-docker.md" %}}
+
+{{% readfile file="/installation/common/05-build-from-source.md" %}}
+
+{{% note %}}
+When building the extended edition of Hugo from source on Windows, you will also need to install the [GCC compiler]. See these [detailed instructions].
+
+[detailed instructions]: https://discourse.gohugo.io/t/41370
+[GCC compiler]: https://gcc.gnu.org/
+{{% /note %}}
+
+## Comparison
+
+||Prebuilt binaries|Package managers|Docker|Build from source
+:--|:--:|:--:|:--:|:--:|:--:
+Easy to install?|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|
+Easy to upgrade?|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:
+Easy to downgrade?|:heavy_check_mark:|:heavy_check_mark: [^2]|:heavy_check_mark:|:heavy_check_mark:
+Automatic updates?|:x:|:x: [^1]|:x: [^1]|:x:
+Latest version available?|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:
+
+[^1]: Possible but requires advanced configuration.
+[^2]: Easy if a previous version is still installed.
diff --git a/content/en/news/0.28-relnotes/index.md b/content/en/news/0.28-relnotes/index.md
index 91128e48e..4d89d2ac7 100644
--- a/content/en/news/0.28-relnotes/index.md
+++ b/content/en/news/0.28-relnotes/index.md
@@ -56,7 +56,7 @@ Hugo now has:
### Other
* Use Chroma as new default syntax highlighter [fb33d828](https://github.com/gohugoio/hugo/commit/fb33d8286d78a78a74deb44355b621852a1c4033) [@bep](https://github.com/bep) [#3888](https://github.com/gohugoio/hugo/issues/3888)
-* Trim newlines in the hightlight shortcode [0d29a0f7](https://github.com/gohugoio/hugo/commit/0d29a0f7819e8d73149701052c29f090cd6db42b) [@bep](https://github.com/bep) [#3898](https://github.com/gohugoio/hugo/issues/3898)
+* Trim newlines in the highlight shortcode [0d29a0f7](https://github.com/gohugoio/hugo/commit/0d29a0f7819e8d73149701052c29f090cd6db42b) [@bep](https://github.com/bep) [#3898](https://github.com/gohugoio/hugo/issues/3898)
* Update `goorgeous` [b8fabce2](https://github.com/gohugoio/hugo/commit/b8fabce217fcb52e3f273491bef95c7977058732) [@bep](https://github.com/bep) [#3899](https://github.com/gohugoio/hugo/issues/3899)
* Add `liveReloadPort` flag to server [b1804776](https://github.com/gohugoio/hugo/commit/b180477631555824a06293053e2b6e63c5f07361) [@bep](https://github.com/bep) [#3882](https://github.com/gohugoio/hugo/issues/3882)
* Add `noHTTPCache` flag to hugo server (default on) [0b34af21](https://github.com/gohugoio/hugo/commit/0b34af216154367af7f53ce93d44e6b3d58c3f34) [@bep](https://github.com/bep) [#3897](https://github.com/gohugoio/hugo/issues/3897)
diff --git a/content/en/news/0.89.4-relnotes/index.md b/content/en/news/0.89.4-relnotes/index.md
index 1f5385f33..f5b24787f 100644
--- a/content/en/news/0.89.4-relnotes/index.md
+++ b/content/en/news/0.89.4-relnotes/index.md
@@ -1,4 +1,3 @@
-
---
date: 2021-11-17
title: "Hugo 0.89.4: One Bug Fix"
@@ -6,14 +5,8 @@ description: "This version fixes one bug introduced in 0.89.0."
categories: ["Releases"]
images:
- images/blog/hugo-bug-poster.png
-
---
-
-
This is a bug-fix release with one important fix for people using `hugo new` to create new content:
* Fix content dir resolution when main project is a Hugo Module [2e70f61f](https://github.com/gohugoio/hugo/commit/2e70f61fb04cea08ef6598728a57637ae2cc199c) [@bep](https://github.com/bep) [#9177](https://github.com/gohugoio/hugo/issues/9177)
-
-
-
diff --git a/content/en/readfiles/dateformatting.md b/content/en/readfiles/dateformatting.md
index 42138dd8a..2aeb60438 100644
--- a/content/en/readfiles/dateformatting.md
+++ b/content/en/readfiles/dateformatting.md
@@ -1,12 +1,12 @@
Go templates [format your dates][time] according to a single reference time:
-```
+```txt
Mon Jan 2 15:04:05 MST 2006
```
You can think of `MST` as `07`, thus making the reference format string a sequence of numbers. The following is [taken directly from the Go docs][gdex]:
-```
+```txt
Jan 2 15:04:05 2006 MST
1 2 3 4 5 6 -7
```
@@ -17,7 +17,7 @@ Each of the following examples show the reference formatting string followed by
Note that the examples were rendered and tested in [CST][] and pull from a single example date you might have in your content's front matter:
-```
+```yml
date: 2017-03-03T14:15:59-06:00
```
@@ -60,13 +60,13 @@ Spelled-out cardinal numbers (e.g. "one", "two", and "three") and ordinal abbrev
To continue with the example above:
-```
+```go-html-template
{{.Date.Format "Jan 2nd 2006"}}
```
Hugo assumes you want to append `nd` as a string to the day of the month and outputs the following:
-```
+```txt
Mar 3nd 2017
```
@@ -84,4 +84,4 @@ In conjunction with the [`dateFormat` function][dateFormat], you can also conver
[dateFormat]: /functions/dateformat/
[gdex]: https://golang.org/pkg/time/#example_Time_Format
[pagevars]: /variables/page/
-[time]: https://golang.org/pkg/time/ \ No newline at end of file
+[time]: https://golang.org/pkg/time/
diff --git a/content/en/readfiles/pages-vs-site-pages.md b/content/en/readfiles/pages-vs-site-pages.md
index df5c7d26e..fbf898980 100644
--- a/content/en/readfiles/pages-vs-site-pages.md
+++ b/content/en/readfiles/pages-vs-site-pages.md
@@ -27,7 +27,7 @@ the current _list_ page:
current _list_ page. This **excludes** regular pages in nested sections/_list_ pages (those are subdirectories with an `_index.md` file.
`.RegularPagesRecursive`
-: {{< new-in "0.68.0" >}} Collection of **all** _regular_ pages under a _list_ page. This **includes** regular pages in nested sections/_list_ pages.
+: Collection of **all** _regular_ pages under a _list_ page. This **includes** regular pages in nested sections/_list_ pages.
Note
: From the scope of _regular_ pages, `.Pages` and
diff --git a/content/en/showcase/alora-labs/bio.md b/content/en/showcase/alora-labs/bio.md
new file mode 100644
index 000000000..d304cf191
--- /dev/null
+++ b/content/en/showcase/alora-labs/bio.md
@@ -0,0 +1,3 @@
+**Alora Labs** is a product development consultancy headquartered in Toronto, Canada.
+
+We help companies build software and IoT products and were recently recognized as one of the [**top IoT development firms**](https://aloralabs.com/insights/alora-labs-receives-clutch-2021-top-iot-agency-award) in Toronto.
diff --git a/content/en/showcase/alora-labs/featured.png b/content/en/showcase/alora-labs/featured.png
new file mode 100644
index 000000000..b8e1f302b
--- /dev/null
+++ b/content/en/showcase/alora-labs/featured.png
Binary files differ
diff --git a/content/en/showcase/alora-labs/index.md b/content/en/showcase/alora-labs/index.md
new file mode 100644
index 000000000..5e6e18131
--- /dev/null
+++ b/content/en/showcase/alora-labs/index.md
@@ -0,0 +1,18 @@
+---
+title: Alora Labs
+date: 2021-05-27
+description: "Showcase: \"Making performant websites accessible for everyone.\""
+siteURL: https://aloralabs.com/
+siteSource: https://github.com/aloralabs/homepage
+aliases: [/showcase/aloralabs/]
+---
+
+At Alora Labs we always have an eye open for new tools and technology that we can utilize to the benefit of our customers or internal projects like our website.
+
+The previous iteration of our site was built with Jekyll, which served us well at first. However as time went on, we became frustrated with the number of dependencies we had to rely on, that would often break at the most inconvenient times.
+
+Hugo was a breath of fresh air in this regard, a single binary that works equally well on Windows as it did on macOS or Linux. We no longer need additional tools for image optimization, Sass compilation or JavaScript bundling. Everything just works, and with a substantial performance boost too.
+
+Hugo has become a favorite tool in the toolbelt and the foundation for many client projects. We couldn't be happier with the switch and we are optimistic about recommending Hugo for many years to come.
+
+Thank you to the vibrant community and talented development team for all the hard work in making Hugo a success. As excellent as Hugo is now, we cannot wait to see what the release notes have in store for us next. \ No newline at end of file
diff --git a/content/en/showcase/ampio-help/bio.md b/content/en/showcase/ampio-help/bio.md
new file mode 100644
index 000000000..c7dd9894a
--- /dev/null
+++ b/content/en/showcase/ampio-help/bio.md
@@ -0,0 +1,11 @@
+
+__We are Ampio.__ We design and manufacture a building automation system that provides control, comfort, safety and reliability. Visit [our page](http://ampio.com/) to learn more about our solution!
+
+__Ampio Knowledge Base__ is a service built and maintained with Hugo. It is a self-service support platform for our customers and certified installers. It also contains a complete portfolio of our modules---building blocks of the Ampio building automation system.
+
+The site is built by:
+
+* [@mgetka](https://github.com/mgetka), developer
+* [@SteynAnna](https://github.com/SteynAnna), maintainer
+
+and other members of the Ampio team responsible for content creation.
diff --git a/content/en/showcase/ampio-help/featured.png b/content/en/showcase/ampio-help/featured.png
new file mode 100644
index 000000000..07974e7f1
--- /dev/null
+++ b/content/en/showcase/ampio-help/featured.png
Binary files differ
diff --git a/content/en/showcase/ampio-help/index.md b/content/en/showcase/ampio-help/index.md
new file mode 100644
index 000000000..198e62fca
--- /dev/null
+++ b/content/en/showcase/ampio-help/index.md
@@ -0,0 +1,77 @@
+---
+title: Ampio Knowledge Base
+date: 2022-10-30
+
+description: "Knowledge base for the Ampio building automation system."
+siteURL: https://help.ampio.com/
+---
+
+As a company that specializes in highly customizable smart solutions for various industries, Ampio has accumulated a vast amount of knowledge throughout the years. We were on the lookout for a user-friendly platform to impart this knowledge to our clients and installers. Delivering a service that caters to both audiences, scattered around the globe with vastly divergent needs and expectations, was a challenge.
+
+On the one hand, we needed something that would let us educate a client with no technical knowledge about our system in a visually appealing way.
+
+On the other hand, our installers required technical drawings, offline manuals, and a deep dive into highly specialized subjects.
+
+Over and above that, we could not overlook the fact that our internal team of editors and maintainers of the Knowledge Base included non-programmers who had to be able to create content and navigate the architecture of the site just as well as those adept at coding.
+
+We started our journey with the following requirements:
+
+ - Ease of contribution
+ - Efficient search capabilities
+ - The possibility of deployment to simple shared hosting
+ - Proper support for multilingualism
+
+## Dark ages of WordPress
+
+With the above-mentioned in mind, we built our first revision of the service in WordPress with a commercial knowledge base plugin. The initial requirements seemed not to be exorbitant, and yet we were surprised to see that only a few of the available solutions covered them. Especially, the case of multilingualism appeared to be particularly neglected across the available products.
+
+The WordPress-based products made big promises: pay some bucks, bootstrap the service in minutes, and forget about all the development troubles. And although those promises could possibly be deliverable on WordPress' end, it was definitely not true for anything more than the most generic deployments. In our case, we were dealing with more and more trade-offs. Plus, the solution was just slow on the simple shared hosting environment that we dedicated to the job.
+
+## Turning point
+
+The turning point was the introduction of a new key requirement---each document was to be downloadable in the PDF format. Such functionality was not available in the plugins we owned, nor did it look like any of the other existing WordPress plugins could fulfill our needs to a satisfactory degree. Nobody in our team was brave enough to add such a functionality to the current stack, so we decided to start from scratch.
+
+On top of that new development, we had to remember another one of our key requirements, namely, that mostly non-programmers were to be responsible for the service maintenance and content creation. Initially, we were leaning towards headless CMS-based solutions, but finally we made a bold move and decided to create a Git-managed Jamstack service and see what happens.
+
+## Hugo to the rescue!
+
+Hugo was our first choice of SSG. The multilingualism support was the primary feature that convinced us. Later on, going through the documentation, we continued to discover new exciting features that we didn't even know we needed when we started.
+
+The rich functionalities of WordPress WYSIWYG editors soon turned out to be a curse. It became burdensome to maintain formatting consistency across documents prepared by multiple contributors. When we considered Markdown, we knew that it would give us a lot less flexibility. In our case, it proved to be a blessing in disguise---the constraints imposed by the notation ensured that each document was prepared in the same way. And in the cases where Markdown was not enough, Hugo shortcodes gave us all that we needed to get the results we anticipated.
+
+In terms of PDF generation, we utilized [custom output formats](https://gohugo.io/templates/output-formats/) to produce intermediary document representations, which are consumed by our custom tool transforming them to TeX documents, which are finally used to produce PDF files.
+
+Custom output formats were also used to create search indexes. The search functionality is built on the brilliant [TNTSearch](https://github.com/teamtnt/tntsearch) library. The search queries and results are handled by PHP snippets embedded into static documents handled by Hugo.
+
+We even implemented a simple REST API generated by Hugo! We have yet to find something that cannot be achieved with this stack, while in WordPress-based solutions we were struggling with things as simple as defining custom document ordering in one of the categories list views.
+
+When talking about Hugo, we cannot forget about the speed. At the beginning we were not considering it a killer feature, but as our document base grew bigger, we appreciated it more and more. Dry-runs are not so common---most of the time we are working on one of the documents with cache already built during one of the previous Hugo runs. In such a scenario, Hugo rebuilds the site in about a second and we consider it a very good result.
+
+```
+ | EN | PL
+-------------------+-----+------
+ Pages | 483 | 486
+ Paginator pages | 56 | 55
+ Non-page files | 745 | 749
+ Static files | 917 | 917
+ Processed images | 487 | 490
+ Aliases | 80 | 79
+ Sitemaps | 2 | 1
+ Cleaned | 0 | 0
+
+Total in 1096 ms
+```
+
+## Adaptation among the contributors
+
+Very quickly it became apparent that our initial concerns about the adaptation of the workflow among contributors were grossly exaggerated. Markdown is fairly straightforward and did not cause any trouble for the contributors.
+
+We recommended that our colleagues use Visual Studio Code as a tool for content creation. The project’s repository tracks project-scoped configuration of the editor, which includes a set of _tasks_ allowing to run a live server from the GUI level. This is very useful for those who are easily frightened when faced with the mighty terminal.
+
+The basic skills of the Git workflow were also easily acquired. At the end of the day, builds and deployments are fully managed by CI/CD processes, so the administration of the service drills down to reviewing and accepting merge requests in the Git frontend. As a side effect, we receive a full and clear history of contributions, which is well appreciated by our quality assurance auditors.
+
+We could even say that our experiment spread the love for Git among non-programmers in our organization!
+
+## Summary
+
+Hugo is the best! Definitely give it a try if you are ever faced with a challenge similar to ours. And do not give it a second thought if your service contributors are not too technically inclined---it might still turn out great!
diff --git a/content/en/showcase/digitalgov/index.md b/content/en/showcase/digitalgov/index.md
index 63f44b645..b06eb355b 100644
--- a/content/en/showcase/digitalgov/index.md
+++ b/content/en/showcase/digitalgov/index.md
@@ -13,7 +13,7 @@ Through collaboration in our communities of practice, Digital.gov is a window in
Digital.gov is built using the [U.S. Web Design System](https://designsystem.digital.gov/) (USWDS) and have followed the [design principles](https://designsystem.digital.gov/maturity-model/) in building out our new site:
- **Start with real user needs** — We used human-centered design methods to inform our product decisions (like qualitative user research), and gathered feedback from real users. We also continually test our assumptions with small experiments.
-- **Earn trust** —We recognize that trust has to be earned every time. We are including all [required links and content](https://digital.gov/resources/required-web-content-and-links/) on our site, clearly identifying as a government site, building with modern best practices, and using https.
+- **Earn trust** —We recognize that trust has to be earned every time. We are including all [required links and content](https://digital.gov/resources/required-web-content-and-links/) on our site, clearly identifying as a government site, building with modern best practices, and using HTTPS.
- **Embrace accessibility** — [Accessibility](https://digital.gov/resources/intro-accessibility/) affects everybody, and we built it into every decision. We’re continually working to conform to Section 508 requirements, use user experience best practices, and support a wide range of devices.
- **Promote continuity** — We started from shared solutions like USWDS and [Federalist](https://federalist.18f.gov/). We designed our site to clearly identify as a government site by including USWDS’s .gov banner, common colors and patterns, and built with modern best practices.
- **Listen** — We actively collect user feedback and web metrics. We use the [Digital Analytics Program](https://digital.gov/services/dap/) (DAP) and analyze the data to discover actionable insights. We make small, incremental changes to continuously improve our website by listening to readers and learning from what we hear.
diff --git a/content/en/showcase/fireship/index.md b/content/en/showcase/fireship/index.md
index e9338a625..a229e4f6a 100644
--- a/content/en/showcase/fireship/index.md
+++ b/content/en/showcase/fireship/index.md
@@ -14,4 +14,4 @@ After careful consideration of JavaScript/JSX-based static site generators, it b
- **Composability.** Hugo's partial and shortcode systems empower us to write DRY and maintainable templates.
- **Simplicity.** Hugo is easy to learn (even without Go experience) and doesn't burden us with brittle dependencies.
-The site is able to achieve Lighthouse performance scores of 95+, despite the fact that it is a fully interactive PWA that ships Angular and Firebase in the JS bundle. This is made possible by (1) prerendering content with Hugo and (2) lazily embedding native web components directly in the HTML and markdown. We provide a [detailed explanation](https://youtu.be/gun8OiGtlNc) of the architecture on YouTube and can't imagine development without Hugo.
+The site is able to achieve Lighthouse performance scores of 95+, despite the fact that it is a fully interactive PWA that ships Angular and Firebase in the JS bundle. This is made possible by (1) prerendering content with Hugo and (2) lazily embedding native web components directly in the HTML and Markdown. We provide a [detailed explanation](https://youtu.be/gun8OiGtlNc) of the architecture on YouTube and can't imagine development without Hugo.
diff --git a/content/en/showcase/forestry/bio.md b/content/en/showcase/forestry/bio.md
index 767365cc0..0b8f28743 100644
--- a/content/en/showcase/forestry/bio.md
+++ b/content/en/showcase/forestry/bio.md
@@ -1,5 +1,4 @@
-Forestry.io is a Git-backed CMS (content management system) for websites and web products built using static site generators such as Hugo.
+Forestry.io is a Git-backed CMS (content management system) for websites and web products built using static site generators such as Hugo.
Forestry bridges the gap between developers and their teams, by making development fun and easy, while providing powerful content management for their teams.
-
diff --git a/content/en/showcase/godot-tutorials/bio.md b/content/en/showcase/godot-tutorials/bio.md
index 92fccadf6..fd849f844 100644
--- a/content/en/showcase/godot-tutorials/bio.md
+++ b/content/en/showcase/godot-tutorials/bio.md
@@ -1,9 +1,7 @@
-
[Godot Tutorials](https://godottutorials.com) aims to teach beginners how to get up and running with basic game programming and game development skills.
The website is built with the **Hugo Framework** alongside aws+cloudfront+lambda.
The site is built by:
-* [Godot Tutorials](https://godottutorials.com)
-
+- [Godot Tutorials](https://godottutorials.com)
diff --git a/content/en/showcase/godot-tutorials/index.md b/content/en/showcase/godot-tutorials/index.md
index e33e413e1..56a8dfc4d 100644
--- a/content/en/showcase/godot-tutorials/index.md
+++ b/content/en/showcase/godot-tutorials/index.md
@@ -15,11 +15,11 @@ byline: "[Godot Tutorials](https://godottutorials.com), Web Developer & Game Pro
[Godot Tutorials](https://godottutorials.com) started as a way to teach beginners game programming and game development.
-As I created videos, I ran into a problem; if I made a mistake with a Youtube video, it was difficult to correct errors.
+As I created videos, I ran into a problem; if I made a mistake with a YouTube video, it was difficult to correct errors.
I discovered that blogging episodes and having articles that teach on top of my videos is a fantastic solution to my problem.
-As I researched blogging platforms, I came across two solutions; however, I chose [Hugo](https://gohugo.io) because it's built with markdown in mind and simplified my workflow.
+As I researched blogging platforms, I came across two solutions; however, I chose [Hugo](https://gohugo.io) because it's built with Markdown in mind and simplified my workflow.
In a sense, with [Hugo](https://gohugo.io) programmed the right way, I can focus **more time on planning, creating, and editing**
my videos and **less time maintaining and fixing** my website. \ No newline at end of file
diff --git a/content/en/showcase/hapticmedia/index.md b/content/en/showcase/hapticmedia/index.md
index 85ec17a8b..7ca2b6cef 100644
--- a/content/en/showcase/hapticmedia/index.md
+++ b/content/en/showcase/hapticmedia/index.md
@@ -1,28 +1,27 @@
---
-
title: Hapticmedia Blog
date: 2019-10-01
description: "Showcase: \"A simple, but powerful, multilingual blog.\""
siteURL: https://hapticmedia.fr/blog/en/
byline: "[Cyril Bonnet](https://github.com/monsieurnebo), Web Developer"
-
---
Our goal was to create a simple, effective and multilingual blog on [3D technology](https://hapticmedia.fr/blog/en/3d-technology/) that could be managed by a non-technical profile.
## Why Hugo?
-Hugo addresses all these needs, coupled with [Forestry.io](https://forestry.io/) for its administration via a "turnkey" interface. We have attached particular importance to SEO, and therefore to the creation of an advanced taxonomy system. Thus, each author and tag has a dedicated page, listing the related posts.
+Hugo addresses all these needs, coupled with [Forestry.io](https://forestry.io/) for its administration via a "turnkey" interface. We have attached particular importance to SEO, and therefore to the creation of an advanced taxonomy system. Thus, each author and tag has a dedicated page, listing the related posts.
## What we liked
+
- The **multilingual** content support, especially simple to setup.
- The **multiple environments** support (develop, staging, test, production, ...).
- Although a hard start with the Go language, the power of the **Hugo's templating**.
- The **partial layouts**, including the `internals` (e.g. social meta tags).
- The **build time**, unbeatable ⚡️⚡️⚡️.
-
## Tools & workflow
+
- We used the same design as **[our website](https://hapticmedia.fr/en/)**, recreated as a Hugo HTML template.
- **[Hugo](https://gohugo.io)** for the static website generator.
- **[CircleCI](https://circleci.com)** for continuous integration & deployment.
diff --git a/content/en/showcase/hartwell-insurance/index.md b/content/en/showcase/hartwell-insurance/index.md
index 925497949..66fc46f44 100644
--- a/content/en/showcase/hartwell-insurance/index.md
+++ b/content/en/showcase/hartwell-insurance/index.md
@@ -20,7 +20,7 @@ It’s a multi-page, single-page (!) website written in Hugo, a static site gene
There’s no Apache or Node backend that does compilation at runtime, it’s all done at the build step. This means the server; Netlify in this case, only has to do one thing – serve files. Unsurprisingly, serving simple files is VERY quick.
-The starter point was the [Victor Hugo](https://github.com/netlify/victor-hugo) repository that Netlify have created. It let me dive in with Hugo, PostCSS, BrowserSync and ES6 without setting up any tooling myself – always a win!
+The starter point was the [Victor Hugo](https://github.com/netlify/victor-hugo) repository that Netlify have created. It let me dive in with Hugo, PostCSS, Browsersync and ES6 without setting up any tooling myself – always a win!
I then took all the content from the design file and moved it into Markdown, putting shortcodes in where necessary. This site did need a number of custom shortcodes for the presentational elements like the expanding circles and full width backgrounds. But mostly it was just clean, semantic HTML with some CSS and JS enhancement thrown in.
diff --git a/content/en/showcase/small-multiples/bio.md b/content/en/showcase/small-multiples/bio.md
deleted file mode 100644
index 3e0c1f14a..000000000
--- a/content/en/showcase/small-multiples/bio.md
+++ /dev/null
@@ -1,3 +0,0 @@
-
-Small Multiples is a multidisciplinary team of data specialists, designers and developers that help people make the best use of their data, a journey that starts from strategy, to concepts, mock-ups, prototypes, design, and development.
-
diff --git a/content/en/showcase/small-multiples/featured-small-multiples.png b/content/en/showcase/small-multiples/featured-small-multiples.png
deleted file mode 100644
index a278f464d..000000000
--- a/content/en/showcase/small-multiples/featured-small-multiples.png
+++ /dev/null
Binary files differ
diff --git a/content/en/showcase/small-multiples/index.md b/content/en/showcase/small-multiples/index.md
deleted file mode 100644
index e2b80ea9a..000000000
--- a/content/en/showcase/small-multiples/index.md
+++ /dev/null
@@ -1,47 +0,0 @@
----
-
-title: Small Multiples
-date: 2018-02-28
-description: "\"Hugo has excellent support and integration with Netlify and we were immediately blown away by how fast it was.\""
-siteURL: https://smallmultiples.com.au/
-byline: "[Small Multiples](https://smallmultiples.com.au/)"
-draft: true
----
-
-Previously we had built and hosted our website with SquareSpace. Although SquareSpace was adequate for quickly showcasing our work, we felt it didn’t reflect our technical capabilities and the types of products we build for our clients.
-
-For many client applications, static front-end sites provide fast, scalable solutions that can easily connect with any back-end service, API or static data. We wanted to use the same processes and infrastructure that we use to host and deploy many of our products, so we felt that building a static site was the right solution for our website.
-
-Netlify is a hosting and deployment service that we use for many products. Our developers really like it because it has strong integration with GitHub and it works with the build tools we use such as Yarn and Webpack. It creates a production build every time we commit to our GitHub repository. This means we can share and preview every change internally or with clients.
-
-Application development has become increasingly complex and there is a strong motivation to simplify this process by avoiding complicated backends in favour of applications that consume static data and APIs (a JAMstack).
-
-Libraries like React make this easy, but we also wanted something that was server rendered. This led us to look at React based tools for static site generation such as GatsbyJS. We liked GatsbyJS, but in the end, we didn’t choose it due to the lack of availability of a simple CMS driven data source.
-
-For this, we considered Contentful. Contentful is a beautifully designed application. It’s basically a headless CMS, but it’s not specifically designed for websites and it becomes quite expensive at a commercial level. Their free tier is possibly a good option for personal sites especially with Gatsby. We also evaluated prose.io. This is a free service for editing markdown files in a GitHub repository. It works well, but it’s quite basic and didn’t provide the editing experience we were looking for.
-
-At the same time, we started exploring Hugo. Hugo is a static site generator similar to Jekyll, but it’s written in Go. It has excellent support and integration with Netlify and we were immediately blown away by how fast it was.
-
-We had been closely following the redevelopment of the Smashing Magazine website. We knew this was being powered by Hugo and Netlify and this showed us that Hugo could work for a large scale sites.
-
-The deciding factor, however, was the availability of CMS options that integrate well with Hugo. Netlify has an open source project called NetlifyCMS and there are also hosted services like Forestry.io. These both provide a CMS with an editing interface for markdown files and images. There is no database, instead, changes are committed directly back into the GitHub repository.
-
-In the end, we chose Hugo on Netlify, with Forestry as our CMS. The site is built and redeployed immediately with Netlify watching for changes to the GitHub repository.
-
-Was this the right choice? For us, yes, but we learnt a few things along the way.
-
-The Hugo templating language was very powerful, although also frustrating at times. The queries used to filter list pages are concise but difficult to read. Although it’s easy to get started, Hugo can have a significant learning curve as you try to do more complicated things.
-
-Hugo has particular expectations when it comes to CMS concepts like tags, categories, RSS, related content and menus. Some parts of our initial design did not match perfectly with how these work in Hugo. It took some time to figure out how to make things work the way we wanted without losing all the benefits of structured content.
-
-There were a few teething issues. We picked some relatively new technologies and as a result, we encountered some bugs. We were forced to find some workarounds and logged some issues with Hugo during the course of development. Most of these were fixed and features were added with releases happening frequently over the time we were working on the project. This can be exciting but also frustrating. We can see Hugo is developing in the right direction.
-
-NetlifyCMS was also very new when we first looked at it and this is partly why we opted for Forestry. Forestry is an excellent choice for an out-of-the-box CMS and it needs very little code configuration. It provided a better editing experience for non-technical users. I would still say this is true, but it also provides fewer options for customisation when compared with NetlifyCMS.
-
-Fortunately, the site is more portable now than it was, or would have been with a dynamic CMS like WordPress, or a fully hosted service like SquareSpace. It should be comparatively easy to swap the publishing functions from Forestry to NetlifyCMS or to change the templates. No part of the pipe-line is tightly coupled, the hosting, the CMS and the templates and the build process can all be updated independently, without changing anything else.
-
-We have complete control over the design and mark-up produced. This means we can implement a better responsive design and have a stronger focus on accessibility and performance.
-
-These technology choices gave us a good performance baseline. It was important to implement a site that took advantage of this. As a data visualisation agency, it can be difficult to optimise for performance with a small bundle size, while also aiming for high-quality visuals and working with large datasets. This meant we spent a lot of time optimising assets making sure there was little blocking the critical path for faster rendering and lazy-load images and videos.
-
-The end result is a high performance site. We think this could have been achieved with GatsbyJS, Hugo or any another static site generator. However, what was important was the decision to use static infrastructure for speed, security, flexibility and hopefully a better ongoing development experience. If you are looking at choosing a static site generator or wondering whether a static is the right choice for you, we hope this has helped.
diff --git a/content/en/showcase/template/index.md b/content/en/showcase/template/index.md
index 06e4a6548..72707bfde 100644
--- a/content/en/showcase/template/index.md
+++ b/content/en/showcase/template/index.md
@@ -1,22 +1,18 @@
---
-
title: Hugo Showcase Template
date: 2018-02-07
description: "A short description of this page."
siteURL: https://gohugo.io/
siteSource: https://github.com/gohugoio/hugoDocs
byline: "[bep](https://github.com/bep), Hugo Lead"
-
---
-
Have a **notable Hugo site[^1]**? We would love to feature it in this **Showcase Section**
-We would really appreciate if you could:
+Please:
-1. Fork https://github.com/gohugoio/hugoDocs
-2. Run `hugo new showcase/your-site` (this requires >= Hugo 0.49). This will use the archetype bundle in the [docs repo](https://github.com/gohugoio/hugoDocs/tree/master/archetypes).
+1. Fork https://github.com/gohugoio/hugoDocs.
+2. Run `hugo new showcase/your-site`. This will use the archetype bundle in the [docs repo](https://github.com/gohugoio/hugoDocs/tree/master/archetypes).
3. Follow the instructions in the newly created page bundle.
-3. Create a new pull request in https://github.com/gohugoio/hugoDocs/pulls
-
+4. Create a new pull request in https://github.com/gohugoio/hugoDocs/pulls.
[^1]: We want this to show Hugo in its best light, so this is not for the average Hugo blog. In most cases the answer to "Is my site [notable](https://www.dictionary.com/browse/notable)?" will be obvious, but if in doubt, create an [issue](https://github.com/gohugoio/hugoDocs/issues) with a link and some words, and we can discuss it. But if you have a site with an interesting Hugo story or a company site where the company itself is notable, you are most welcome.
diff --git a/content/en/templates/404.md b/content/en/templates/404.md
index 2be629437..81c4c38bd 100644
--- a/content/en/templates/404.md
+++ b/content/en/templates/404.md
@@ -22,7 +22,7 @@ When using Hugo with [GitHub Pages](https://pages.github.com/), you can provide
In addition to the standard page variables, the 404 page has access to all site content accessible from `.Pages`.
-```
+```txt
▾ layouts/
404.html
```
@@ -52,7 +52,8 @@ Your 404.html file can be set to load automatically when a visitor enters a mist
* Amazon CloudFront. You can specify the page in the Error Pages section in the CloudFront Console. [Details here](https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html)
* Caddy Server. Use the `handle_errors` directive to specify error pages for one or more status codes. [Details here](https://caddyserver.com/docs/caddyfile/directives/handle_errors)
* Netlify. Add `/* /404.html 404` to `content/_redirects`. [Details Here](https://www.netlify.com/docs/redirects/#custom-404)
-* Azure Static website. You can specify the `Error document path` in the Static website configuration page of the Azure portal. [More details are available in the Static website documentation](https://docs.microsoft.com/en-us/azure/storage/blobs/storage-blob-static-website).
+* Azure Static Web App. set `responseOverrides.404.rewrite` and `responseOverrides.404.statusCode` in configfile `staticwebapp.config.json`. [Details here](https://docs.microsoft.com/en-us/azure/static-web-apps/configuration#response-overrides)
+* Azure Storage as Static Web Site Hosting. You can specify the `Error document path` in the Static website configuration page of the Azure portal. [Details here](https://docs.microsoft.com/en-us/azure/storage/blobs/storage-blob-static-website).
* DigitalOcean App Platform. You can specify `error_document` in your app specification file or use control panel to set up error document. [Details here](https://docs.digitalocean.com/products/app-platform/how-to/manage-static-sites/#configure-a-static-site).
* [Firebase Hosting](https://firebase.google.com/docs/hosting/full-config#404): `/404.html` automatically gets used as the 404 page.
diff --git a/content/en/templates/alternatives.md b/content/en/templates/alternatives.md
deleted file mode 100644
index c5fde5b51..000000000
--- a/content/en/templates/alternatives.md
+++ /dev/null
@@ -1,21 +0,0 @@
----
-title: DEPRECATED - Alternative Templating Languages
-linktitle: Alternative Templating
-description: DEPRECATED - Support for Ace & Amber templating has been removed in version 0.62
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-20
-categories: [templates]
-keywords: [amber,ace,templating languages]
-menu:
- docs:
- parent: "templates"
- weight: 170
-weight: 170
-sections_weight: 170
-draft: false
-aliases: [/templates/ace/,/templates/amber/]
-toc: true
----
-
-Support for Amber and Ace templates has been removed since Hugo 0.62 per [issue #6609](https://github.com/gohugoio/hugo/issues/6609).
diff --git a/content/en/templates/base.md b/content/en/templates/base.md
index f2648bd52..c82cc09a1 100644
--- a/content/en/templates/base.md
+++ b/content/en/templates/base.md
@@ -4,7 +4,6 @@ linktitle:
description: The base and block constructs allow you to define the outer shell of your master templates (i.e., the chrome of the page).
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [templates,fundamentals]
keywords: [blocks,base]
menu:
@@ -24,7 +23,7 @@ The `block` keyword allows you to define the outer shell of your pages' one or m
## Base Template Lookup Order
-{{< new-in "0.63.0" >}} Since Hugo v0.63, the base template lookup order closely follows that of the template it applies to (e.g. `_default/list.html`).
+The base template lookup order closely follows that of the template it applies to (e.g. `_default/list.html`).
See [Template Lookup Order](/templates/lookup-order/) for details and examples.
@@ -75,7 +74,7 @@ This replaces the contents of our (basically empty) "main" block with something
{{% warning %}}
Code that you put outside the block definitions *can* break your layout. This even includes HTML comments. For example:
-```
+```go-html-template
<!-- Seemingly harmless HTML comment..that will break your layout at build -->
{{ define "main" }}
...your code here
diff --git a/content/en/templates/data-templates.md b/content/en/templates/data-templates.md
index bd1ed6d76..1be4e93eb 100644
--- a/content/en/templates/data-templates.md
+++ b/content/en/templates/data-templates.md
@@ -4,7 +4,6 @@ linktitle:
description: In addition to Hugo's built-in variables, you can specify your own custom data in templates or shortcodes that pull from both local and dynamic sources.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-03-12
categories: [templates]
keywords: [data,dynamic,csv,json,toml,yaml,xml]
menu:
@@ -13,7 +12,6 @@ menu:
weight: 80
weight: 80
sections_weight: 80
-draft: false
aliases: [/extras/datafiles/,/extras/datadrivencontent/,/doc/datafiles/]
toc: true
---
@@ -30,9 +28,23 @@ The `data` folder is where you can store additional data for Hugo to use when ge
These files must be YAML, JSON, XML, or TOML files (using the `.yml`, `.yaml`, `.json`, `.xml`, or `.toml` extension). The data will be accessible as a `map` in the `.Site.Data` variable.
+If you wish to access the data using the `.Site.Data.filename` notation, the filename must begin with an underscore or a Unicode letter, followed by zero or more underscores, Unicode letters, or Unicode digits. eg:
+
+- `123.json` - Invalid
+- `x123.json` - Valid
+- `_123.json` - Valid
+
+If you wish to access the data using the [`index`](/functions/index-function/) function, the filename is irrelevant. For example:
+Data file|Template code
+:--|:--
+`123.json`|`{{ index .Site.Data "123" }}`
+`x123.json`|`{{ index .Site.Data "x123" }}`
+`_123.json`|`{{ index .Site.Data "_123" }}`
+`x-123.json`|`{{ index .Site.Data "x-123" }}`
+
## Data Files in Themes
-Data Files can also be used in [Hugo themes][themes] but note that theme data files follow the same logic as other template files in the [Hugo lookup order][lookup] (i.e., given two files with the same name and relative path, the file in the root project `data` directory will override the file in the `themes/<THEME>/data` directory).
+Data Files can also be used in [Hugo themes][themes] but note that theme data files are merged with the project directory taking precedence (i.e., given two files with the same name and relative path, the data in the file in the root project `data` directory will override the data from the file in the `themes/<THEME>/data` directory *for keys that are duplicated*).
Therefore, theme authors should take care to not include data files that could be easily overwritten by a user who decides to [customize a theme][customize]. For theme-specific data items that shouldn't be overridden, it can be wise to prefix the folder structure with a namespace; e.g. `mytheme/data/<THEME>/somekey/...`. To check if any such duplicate exists, run hugo with the `-v` flag.
@@ -75,7 +87,7 @@ The list of bass players can be accessed via `.Site.Data.jazz.bass`, a single ba
You can now render the list of recordings for all the bass players in a template:
-```
+```go-html-template
{{ range $.Site.Data.jazz.bass }}
{{ partial "artist.html" . }}
{{ end }}
@@ -83,7 +95,7 @@ You can now render the list of recordings for all the bass players in a template
And then in the `partials/artist.html`:
-```
+```go-html-template
<ul>
{{ range .discography }}
<li>{{ . }}</li>
@@ -108,7 +120,7 @@ Achievements:
You can use the following code to render the `Short Description` in your layout:
-```
+```go-html-template
<div>Short Description of {{.Site.Data.User0123.Name}}: <p>{{ index .Site.Data.User0123 "Short Description" | markdownify }}</p></div>
```
@@ -119,14 +131,14 @@ Note the use of the [`markdownify` template function][markdownify]. This will se
Use `getJSON` or `getCSV` to get remote data:
-```
+```go-html-template
{{ $dataJ := getJSON "url" }}
{{ $dataC := getCSV "separator" "url" }}
```
If you use a prefix or postfix for the URL, the functions accept [variadic arguments][variadic]:
-```
+```go-html-template
{{ $dataJ := getJSON "url prefix" "arg1" "arg2" "arg n" }}
{{ $dataC := getCSV "separator" "url prefix" "arg1" "arg2" "arg n" }}
```
@@ -135,28 +147,28 @@ The separator for `getCSV` must be put in the first position and can only be one
All passed arguments will be joined to the final URL:
-```
+```go-html-template
{{ $urlPre := "https://api.github.com" }}
{{ $gistJ := getJSON $urlPre "/users/GITHUB_USERNAME/gists" }}
```
This will resolve internally to the following:
-```
+```go-html-template
{{ $gistJ := getJSON "https://api.github.com/users/GITHUB_USERNAME/gists" }}
```
### Add HTTP headers
-{{< new-in "0.84.0" >}} Both `getJSON` and `getCSV` takes an optional map as the last argument, e.g.:
+Both `getJSON` and `getCSV` takes an optional map as the last argument, e.g.:
-```
+```go-html-template
{{ $data := getJSON "https://example.org/api" (dict "Authorization" "Bearer abcd") }}
```
If you need multiple values for the same header key, use a slice:
-```
+```go-html-template
{{ $data := getJSON "https://example.org/api" (dict "X-List" (slice "a" "b" "c")) }}
```
@@ -197,7 +209,7 @@ With the command-line flag `--cacheDir`, you can specify any folder on your syst
You can also set `cacheDir` in the [main configuration file][config].
-If you don't like caching at all, you can fully disable caching with the command line flag `--ignoreCache`.
+If you don't like caching at all, you can fully disable caching with the command-line flag `--ignoreCache`.
### Authentication When Using REST URLs
@@ -210,7 +222,7 @@ To load local files with `getJSON` and `getCSV`, the source files must reside wi
It applies the same output logic as above in [Get Remote Data](#get-remote-data).
{{% note %}}
-The local CSV files to be loaded using `getCSV` must be located **outside** of the `data` directory.
+The local CSV files to be loaded using `getCSV` must be located **outside** the `data` directory.
{{% /note %}}
## LiveReload with Data Files
diff --git a/content/en/templates/files.md b/content/en/templates/files.md
index c2de11292..697863c4c 100644
--- a/content/en/templates/files.md
+++ b/content/en/templates/files.md
@@ -37,15 +37,15 @@ The [`readfile` function][readFile] reads a file from disk and converts it into
To use the `readFile` function in your templates, make sure the path is relative to your *Hugo project's root directory*:
-```
+```go-html-template
{{ readFile "/content/templates/local-file-templates" }}
```
### `readFile` Example: Add a Project File to Content
-As `readFile` is a function, it is only available to you in your templates and not your content. However, we can create a simple [shortcode template][sct] that calls `readFile`, passes the first argument through the function, and then allows an optional second argument to send the file through the markdown processor. The pattern for adding this shortcode to your content will be as follows:
+As `readFile` is a function, it is only available to you in your templates and not your content. However, we can create a simple [shortcode template][sct] that calls `readFile`, passes the first argument through the function, and then allows an optional second argument to send the file through the Markdown processor. The pattern for adding this shortcode to your content will be as follows:
-```
+```go-html-template
{{</* readfile file="/path/to/local/file.txt" markdown="true" */>}}
```
@@ -53,8 +53,6 @@ As `readFile` is a function, it is only available to you in your templates and n
If you are going to create [custom shortcodes](/templates/shortcode-templates/) with `readFile` for a theme, note that usage of the shortcode will refer to the project root and *not* your `themes` directory.
{{% /warning %}}
-
-
[called directly in the Hugo docs]: https://github.com/gohugoio/hugoDocs/blob/master/content/en/templates/files.md
[dirindex]: https://github.com/gohugoio/hugo/blob/master/docs/layouts/shortcodes/directoryindex.html
[osfileinfo]: https://golang.org/pkg/os/#FileInfo
diff --git a/content/en/templates/internal.md b/content/en/templates/internal.md
index ace21f548..a92a0f551 100644
--- a/content/en/templates/internal.md
+++ b/content/en/templates/internal.md
@@ -27,38 +27,42 @@ While the following internal templates are called similar to partials, they do *
## Google Analytics
-Hugo ships with internal templates for Google Analytics tracking, including both synchronous and asynchronous tracking codes. As well as support for both v3 and v4 of Google Analytics.
+Hugo ships with internal templates supporting Google Analytics, both [Google Analytics 4][GA4] (GA4) and Universal Analytics.
+
+**Note:** Universal Analytics are deprecated. For details, see [Universal Analytics will be going away][].
+
+[GA4]: https://support.google.com/analytics/answer/10089681
+[Universal Analytics will be going away]: https://support.google.com/analytics/answer/11583528
### Configure Google Analytics
-Provide your tracking id in your configuration file:
+Provide your tracking ID in your configuration file:
-**Google Analytics v3 (analytics.js)**
+**Google Analytics 4 (gtag.js)**
{{< code-toggle file="config" >}}
-googleAnalytics = "UA-PROPERTY_ID"
+googleAnalytics = "G-MEASUREMENT_ID"
{{</ code-toggle >}}
-**Google Analytics v4 (gtag.js)**
+**Google Universal Analytics (analytics.js)**
{{< code-toggle file="config" >}}
-googleAnalytics = "G-MEASUREMENT_ID"
+googleAnalytics = "UA-PROPERTY_ID"
{{</ code-toggle >}}
### Use the Google Analytics Template
You can then include the Google Analytics internal template:
-```
-{{ template "_internal/google_analytics.html" . }}
+```go-html-template
+{{ template "_internal/google_analytics_async.html" . }}
```
+**Note:** The async template is _not_ suitable for Google Analytics 4.
+```go-html-template
+{{ template "_internal/google_analytics.html" . }}
```
-{{ template "_internal/google_analytics_async.html" . }}
-```
-
-When using Google Analytics v4 use `_internal/google_analytics.html`.
-A `.Site.GoogleAnalytics` variable is also exposed from the config.
+If you want to create your own template, you can access the configured ID with `{{ site.Config.Services.GoogleAnalytics.ID }}`.
## Disqus
@@ -82,7 +86,7 @@ You also have the option to set the following in the front matter for a given pi
To add Disqus, include the following line in templates where you want your comments to appear:
-```
+```go-html-template
{{ template "_internal/disqus.html" . }}
```
@@ -118,11 +122,12 @@ The `if` statement skips the initialization of the Disqus comment injection when
You can then render your custom Disqus partial template as follows:
-```
+```go-html-template
{{ partial "disqus.html" . }}
```
## Open Graph
+
An internal template for the [Open Graph protocol](https://ogp.me/), metadata that enables a page to become a rich object in a social graph.
This format is used for Facebook and some other sites.
@@ -167,7 +172,7 @@ If using YouTube this will produce a og:video tag like `<meta property="og:video
To add Open Graph metadata, include the following line between the `<head>` tags in your templates:
-```
+```go-html-template
{{ template "_internal/opengraph.html" . }}
```
@@ -198,16 +203,31 @@ If no images are found at all, then an image-less Twitter `summary` card is used
Hugo uses the page title and description for the card's title and description fields. The page summary is used if no description is given.
-### Use the Twitter Cards Template
+The `.Site.Social.twitter` variable is exposed from the config as the value for `twitter:site`.
-To add Twitter card metadata, include the following line between the `<head>` tags in your templates:
+{{< code-toggle file="config" >}}
+[social]
+ twitter = "GoHugoIO"
+{{</ code-toggle >}}
+NOTE: The `@` will be added for you
+
+```html
+<meta name="twitter:site" content="@GoHugoIO"/>
```
+
+### Use the Twitter Cards Template
+
+To add Twitter card metadata, include the following line immediately after the `<head>` element in your templates:
+
+```go-html-template
{{ template "_internal/twitter_cards.html" . }}
```
## The Internal Templates
+The code for these templates is located [here](https://github.com/gohugoio/hugo/tree/master/tpl/tplimpl/embedded/templates).
+
* `_internal/disqus.html`
* `_internal/google_analytics.html`
* `_internal/google_analytics_async.html`
diff --git a/content/en/templates/introduction.md b/content/en/templates/introduction.md
index ba66afa86..01f448778 100644
--- a/content/en/templates/introduction.md
+++ b/content/en/templates/introduction.md
@@ -4,7 +4,7 @@ linktitle: Templating
description: Hugo uses Go's `html/template` and `text/template` libraries as the basis for the templating.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-25
+lastmod: 2022-09-20
categories: [templates,fundamentals]
keywords: [go]
menu:
@@ -43,7 +43,7 @@ current scope (like the `.Title` example in the [Variables]({{< relref
Parameters for functions are separated using spaces. The general syntax is:
-```
+```go-html-template
{{ FUNCTION ARG1 ARG2 .. }}
```
@@ -70,8 +70,8 @@ Accessing the Page Parameter `bar` defined in a piece of content's [front matter
#### A Single Statement Can be Split over Multiple Lines
```go-html-template
-{{ if or
- (isset .Params "alt")
+{{ if or
+ (isset .Params "alt")
(isset .Params "caption")
}}
```
@@ -107,6 +107,7 @@ The custom variables need to be prefixed with `$`.
{{ $address := "123 Main St." }}
{{ $address }}
```
+
Variables can be re-defined using the `=` operator. The example below
prints "Var is Hugo Home" on the home page, and "Var is Hugo Page" on
all other pages:
@@ -139,7 +140,7 @@ Go Templates only ship with a few basic functions but also provide a mechanism f
<!-- prints true (i.e., since 1 is less than 2) -->
```
-Note that both examples make use of Go Template's [math]][] functions.
+Note that both examples make use of Go Template's [math][math] functions.
{{% note "Additional Boolean Operators" %}}
There are more boolean operators than those listed in the Hugo docs in the [Go Template documentation](https://golang.org/pkg/text/template/#hdr-Functions).
@@ -159,7 +160,7 @@ within Hugo.
### Partial
-The [`partial`][partials] function is used to include *partial* templates using
+The [`partial`][partials] function is used to include _partial_ templates using
the syntax `{{ partial "<PATH>/<PARTIAL>.<EXTENSION>" . }}`.
Example of including a `layouts/partials/header.html` partial:
@@ -170,9 +171,9 @@ Example of including a `layouts/partials/header.html` partial:
### Template
-The `template` function was used to include *partial* templates
+The `template` function was used to include _partial_ templates
in much older Hugo versions. Now it's useful only for calling
-[*internal* templates][internal templates]. The syntax is `{{ template
+[_internal_ templates][internal templates]. The syntax is `{{ template
"_internal/<TEMPLATE>.<EXTENSION>" . }}`.
{{% note %}}
@@ -234,7 +235,7 @@ key.
{{ end }}
```
-#### Example 5: Conditional on empty _map_, _array_, or _slice_.
+#### Example 5: Conditional on empty _map_, _array_, or _slice_
If the _map_, _array_, or _slice_ passed into the range is zero-length then the else statement is evaluated.
@@ -293,7 +294,7 @@ See the [`.Param` function][param].
#### Example 3: `if`
An alternative (and a more verbose) way of writing `with` is using
-`if`. Here, the `.` does not get rebinded.
+`if`. Here, the `.` does not get rebound.
Below example is "Example 1" rewritten using `if`:
@@ -382,22 +383,6 @@ Stuff Here
{{ end }}
```
-### Example 4: Internet Explorer Conditional Comments {#ie-conditional-comments}
-
-By default, Go Templates remove HTML comments from output. This has the unfortunate side effect of removing Internet Explorer conditional comments. As a workaround, use something like this:
-
-```go-html-template
-{{ "<!--[if lt IE 9]>" | safeHTML }}
- <script src="html5shiv.js"></script>
-{{ "<![endif]-->" | safeHTML }}
-```
-
-Alternatively, you can use the backtick (`` ` ``) to quote the IE conditional comments, avoiding the tedious task of escaping every double quotes (`"`) inside, as demonstrated in the [examples](https://golang.org/pkg/text/template/#hdr-Examples) in the Go text/template documentation:
-
-```go-html-template
-{{ `<!--[if lt IE 7]><html class="no-js lt-ie9 lt-ie8 lt-ie7"><![endif]-->` | safeHTML }}
-```
-
## Context (aka "the dot") {#the-dot}
The most easily overlooked concept to understand about Go Templates is
@@ -405,7 +390,7 @@ that `{{ . }}` always refers to the **current context**.
- In the top level of your template, this will be the data set made
available to it.
-- Inside of an iteration, however, it will have the value of the
+- Inside an iteration, however, it will have the value of the
current item in the loop; i.e., `{{ . }}` will no longer refer to
the data available to the entire page.
@@ -430,7 +415,7 @@ The following shows how to define a variable independent of the context.
{{< /code >}}
{{% note %}}
-Notice how once we have entered the loop (i.e. `range`), the value of `{{ . }}` has changed. We have defined a variable outside of the loop (`{{$title}}`) that we've assigned a value so that we have access to the value from within the loop as well.
+Notice how once we have entered the loop (i.e. `range`), the value of `{{ . }}` has changed. We have defined a variable outside the loop (`{{$title}}`) that we've assigned a value so that we have access to the value from within the loop as well.
{{% /note %}}
### 2. Use `$.` to Access the Global Context
@@ -511,7 +496,7 @@ Will render `Bonsoir, Eliott.`, and not care about the syntax error (`add 0 + 2`
### HTML comments
-If you need to produce HTML comments from your templates, take a look at the [Internet Explorer conditional comments](#ie-conditional-comments) example. If you need variables to construct such HTML comments, just pipe `printf` to `safeHTML`. For example:
+If you need to produce HTML comments from your templates, take a look at the [Internet Explorer conditional comments]({{< relref "introduction.md#ie-conditional-comments" >}}) example. If you need variables to construct such HTML comments, just pipe `printf` to `safeHTML`. For example:
```go-html-template
{{ printf "<!-- Our website is named: %s -->" .Site.Title | safeHTML }}
@@ -544,7 +529,7 @@ An example of this is used in the Hugo docs. Most of the pages benefit from havi
Here is the example front matter (YAML):
-```
+```yml
---
title: Roadmap
lastmod: 2017-03-05
diff --git a/content/en/templates/lists.md b/content/en/templates/lists.md
index 97dc0f40d..18f03c6f1 100644
--- a/content/en/templates/lists.md
+++ b/content/en/templates/lists.md
@@ -59,7 +59,7 @@ It is important to note that all `_index.md` content files will render according
The following is an example of a typical Hugo project directory's content:
-```
+```txt
.
...
├── content
@@ -524,27 +524,27 @@ While these are logical defaults, they are not always the desired order. There a
#### 1. Adding the Reverse Method
-```
+```go-html-template
{{ range (.Pages.GroupBy "Section").Reverse }}
```
-```
+```go-html-template
{{ range (.Pages.GroupByDate "2006-01").Reverse }}
```
#### 2. Providing the Alternate Direction
-```
+```go-html-template
{{ range .Pages.GroupByDate "2006-01" "asc" }}
```
-```
+```go-html-template
{{ range .Pages.GroupBy "Section" "desc" }}
```
### Order Within Groups
-Because Grouping returns a `{{.Key}}` and a slice of pages, all of the ordering methods listed above are available.
+Because Grouping returns a `{{.Key}}` and a slice of pages, all the ordering methods listed above are available.
Here is the ordering for the example that follows:
diff --git a/content/en/templates/lookup-order.md b/content/en/templates/lookup-order.md
index e021c8112..edb03839e 100644
--- a/content/en/templates/lookup-order.md
+++ b/content/en/templates/lookup-order.md
@@ -39,7 +39,7 @@ Language
: We will consider a language code in the template name. If the site language is `fr`, `index.fr.amp.html` will win over `index.amp.html`, but `index.amp.html` will be chosen before `index.fr.html`.
Type
-: Is value of `type` if set in front matter, else it is the name of the root section (e.g. "blog"). It will always have a value, so if not set, the value is "page".
+: Is value of `type` if set in front matter, else it is the name of the root section (e.g. "blog"). It will always have a value, so if not set, the value is "page".
Section
: Is relevant for `section`, `taxonomy` and `term` types.
diff --git a/content/en/templates/menu-templates.md b/content/en/templates/menu-templates.md
index dd7ab380f..bdf89c2e5 100644
--- a/content/en/templates/menu-templates.md
+++ b/content/en/templates/menu-templates.md
@@ -20,8 +20,8 @@ toc: false
---
Hugo makes no assumptions about how your rendered HTML will be
-structured. Instead, it provides all of the functions you will need to be
-able to build your menu however you want.
+structured. Instead, it provides all the functions you will need to
+build your menu however you want.
The following is an example:
@@ -72,17 +72,17 @@ Use the [`absLangURL`](/functions/abslangurl) or [`relLangURL`](/functions/rella
To enable this menu, configure `sectionPagesMenu` in your site `config`:
-```
+```yml
sectionPagesMenu = "main"
```
-The menu name can be anything, but take a note of what it is.
+The menu name can be anything, but take a note of what it is.
This will create a menu with all the sections as menu items and all the sections' pages as "shadow-members". Ensure that all first level directories that you would like to show up on this menu are [Branch Bundles](https://gohugo.io/content-management/sections/). Leaf Bundles do not form sections.
The _shadow_ implies that the pages isn't represented by a menu-item themselves, but this enables you to create a top-level menu like this:
-```
+```go-html-template
<nav class="sidebar-nav">
{{ $currentPage := . }}
{{ range .Site.Menus.main }}
@@ -93,7 +93,6 @@ The _shadow_ implies that the pages isn't represented by a menu-item themselves,
In the above, the menu item is marked as active if on the current section's list page or on a page in that section.
-
## Site Config menus
The above is all that's needed. But if you want custom menu items, e.g. changing weight, name, or link title attribute, you can define them manually in the site config file:
@@ -117,7 +116,7 @@ It's also possible to create menu entries from the page (i.e. the `.md`-file).
Here is a `yaml` example:
-```
+```yml
---
title: Menu Templates
linktitle: Menu Templates
@@ -148,7 +147,7 @@ That's why you have to use the go template's `with` keyword or something similar
Here's an example:
-```
+```go-html-template
<nav class="sidebar-nav">
{{ range .Site.Menus.main }}
<a href="{{ .URL }}" title="{{ .Title }}">
@@ -169,7 +168,7 @@ User-defined content on menu items are accessible via `.Params`.
Here's an example:
-```
+```go-html-template
<nav class="sidebar-nav">
{{ range .Site.Menus.main }}
<a href="{{ .URL }}" title="{{ .Title }}" class="{{ with .Params.class }}{{ . }}{{ end }}">
diff --git a/content/en/templates/ordering-and-grouping.md b/content/en/templates/ordering-and-grouping.md
deleted file mode 100644
index f1634c7d8..000000000
--- a/content/en/templates/ordering-and-grouping.md
+++ /dev/null
@@ -1,344 +0,0 @@
----
-title: Ordering and Grouping Hugo Lists
-linktitle: List Ordering and Grouping
-description: You can group or order your content in both your templating and content front matter.
-date: 2017-02-01
-publishdate: 2017-02-01
-lastmod: 2017-02-01
-categories: [templates]
-keywords: []
-menu:
- docs:
- parent: "templates"
- weight: 27
-weight: 27
-sections_weight: 27
-draft: true
-aliases: [/templates/ordering/,/templates/grouping/]
-toc: true
-notes: This was originally going to be a separate page on the new docs site but it now makes more sense to keep everything within the templates/lists page. - rdwatters, 2017-03-12.
----
-
-In Hugo, a list template is any template that will be used to render multiple pieces of content in a single HTML page.
-
-## Example List Templates
-
-### Section Template
-
-This list template is used for [spf13.com](https://spf13.com/). It makes use of [partial templates][partials]. All examples use a [view](/templates/views/) called either "li" or "summary."
-
-{{< code file="layouts/section/post.html" >}}
-{{ partial "header.html" . }}
-{{ partial "subheader.html" . }}
-
-<section id="main">
- <div>
- <h1 id="title">{{ .Title }}</h1>
- <ul id="list">
- {{ range .Pages }}
- {{ .Render "li"}}
- {{ end }}
- </ul>
- </div>
-</section>
-{{ partial "footer.html" . }}
-{{< /code >}}
-
-### Taxonomy Template
-
-{{< code file="layouts/_default/taxonomies.html" download="taxonomies.html" >}}
-{{ define "main" }}
-<section id="main">
- <div>
- <h1 id="title">{{ .Title }}</h1>
- {{ range .Pages }}
- {{ .Render "summary"}}
- {{ end }}
- </div>
-</section>
-{{ end }}
-{{< /code >}}
-
-## Order Content
-
-Hugo lists render the content based on metadata provided in the [front matter](/content-management/front-matter/)..
-
-Here are a variety of different ways you can order the content items in
-your list templates:
-
-### Default: Weight > Date
-
-{{< code file="layouts/partials/order-default.html" >}}
-<ul class="pages">
- {{ range .Pages }}
- <li>
- <h1><a href="{{ .Permalink }}">{{ .Title }}</a></h1>
- <time>{{ .Date.Format "Mon, Jan 2, 2006" }}</time>
- </li>
- {{ end }}
-</ul>
-{{< /code >}}
-
-### By Weight
-
-{{< code file="layouts/partials/by-weight.html" >}}
-{{ range .Pages.ByWeight }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
-{{ end }}
-{{< /code >}}
-
-### By Date
-
-{{< code file="layouts/partials/by-date.html" >}}
-{{ range .Pages.ByDate }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
-{{ end }}
-{{< /code >}}
-
-### By Publish Date
-
-{{< code file="layouts/partials/by-publish-date.html" >}}
-{{ range .Pages.ByPublishDate }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .PublishDate.Format "Mon, Jan 2, 2006" }}</div>
- </li>
-{{ end }}
-{{< /code >}}
-
-### By Expiration Date
-
-{{< code file="layouts/partials/by-expiry-date.html" >}}
-{{ range .Pages.ByExpiryDate }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .ExpiryDate.Format "Mon, Jan 2, 2006" }}</div>
- </li>
-{{ end }}
-{{< /code >}}
-
-### By Last Modified Date
-
-{{< code file="layouts/partials/by-last-mod.html" >}}
-{{ range .Pages.ByLastmod }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
-{{ end }}
-{{< /code >}}
-
-### By Length
-
-{{< code file="layouts/partials/by-length.html" >}}
-{{ range .Pages.ByLength }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
-{{ end }}
-{{< /code >}}
-
-
-### By Title
-
-{{< code file="layouts/partials/by-title.html" >}}
-{{ range .Pages.ByTitle }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
-{{ end }}
-{{< /code >}}
-
-### By Link Title
-
-{{< code file="layouts/partials/by-link-title.html" >}}
-{{ range .Pages.ByLinkTitle }}
- <li>
- <a href="{{ .Permalink }}">{{ .LinkTitle }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
-{{ end }}
-{{< /code >}}
-
-### By Parameter
-
-Order based on the specified front matter parameter. Content that does not have the specified front matter field will use the site's `.Site.Params` default. If the parameter is not found at all in some entries, those entries will appear together at the end of the ordering.
-
-The below example sorts a list of posts by their rating.
-
-{{< code file="layouts/partials/by-rating.html" >}}
-{{ range (.Pages.ByParam "rating") }}
- <!-- ... -->
-{{ end }}
-{{< /code >}}
-
-If the front matter field of interest is nested beneath another field, you can
-also get it:
-
-{{< code file="layouts/partials/by-nested-param.html" >}}
-{{ range (.Pages.ByParam "author.last_name") }}
- <!-- ... -->
-{{ end }}
-{{< /code >}}
-
-### Reverse Order
-
-Reversing order can be applied to any of the above methods. The following uses `ByDate` as an example:
-
-{{< code file="layouts/partials/by-date-reverse.html" >}}
-{{ range .Pages.ByDate.Reverse }}
-<li>
-<a href="{{ .Permalink }}">{{ .Title }}</a>
-<div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
-</li>
-{{ end }}
-{{< /code >}}
-
-## Group Content
-
-Hugo provides some functions for grouping pages by Section, Type, Date, etc.
-
-### By Page Field
-
-{{< code file="layouts/partials/by-page-field.html" >}}
-{{ range .Pages.GroupBy "Section" }}
-<h3>{{ .Key }}</h3>
-<ul>
- {{ range .Pages }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
- {{ end }}
-</ul>
-{{ end }}
-{{< /code >}}
-
-### By Page date
-
-{{< code file="layouts/partials/by-page-date.html" >}}
-{{ range .Pages.GroupByDate "2006-01" }}
-<h3>{{ .Key }}</h3>
-<ul>
- {{ range .Pages }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
- {{ end }}
-</ul>
-{{ end }}
-{{< /code >}}
-
-### By Page publish date
-
-{{< code file="layouts/partials/by-page-publish-date.html" >}}
-{{ range .Pages.GroupByPublishDate "2006-01" }}
-<h3>{{ .Key }}</h3>
-<ul>
- {{ range .Pages }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .PublishDate.Format "Mon, Jan 2, 2006" }}</div>
- </li>
- {{ end }}
-</ul>
-{{ end }}
-{{< /code >}}
-
-### By Page Param
-
-{{< code file="layouts/partials/by-page-param.html" >}}
-{{ range .Pages.GroupByParam "param_key" }}
-<h3>{{ .Key }}</h3>
-<ul>
- {{ range .Pages }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
- {{ end }}
-</ul>
-{{ end }}
-{{< /code >}}
-
-### By Page Param in Date Format
-
-{{< code file="layouts/partials/by-page-param-as-date.html" >}}
-{{ range .Pages.GroupByParamDate "param_key" "2006-01" }}
-<h3>{{ .Key }}</h3>
-<ul>
- {{ range .Pages }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
- {{ end }}
-</ul>
-{{ end }}
-{{< /code >}}
-
-### Reverse Key Order
-
-The ordering of the groups is performed by keys in alphanumeric order (A–Z, 1–100) and in reverse chronological order (newest first) for dates.
-
-While these are logical defaults, they are not always the desired order. There are two different syntaxes to change the order, both of which work the same way. You can use your preferred syntax.
-
-#### Reverse Method
-
-```
-{{ range (.Pages.GroupBy "Section").Reverse }}
-```
-
-```
-{{ range (.Pages.GroupByDate "2006-01").Reverse }}
-```
-
-
-#### Provide the Alternate Direction
-
-```
-{{ range .Pages.GroupByDate "2006-01" "asc" }}
-```
-
-```
-{{ range .Pages.GroupBy "Section" "desc" }}
-```
-
-### Order Within Groups
-
-Because Grouping returns a `{{.Key}}` and a slice of pages, all of the ordering methods listed above are available.
-
-In the following example, groups are ordered chronologically and then content
-within each group is ordered alphabetically by title.
-
-{{< code file="layouts/partials/by-group-by-page.html" >}}
-{{ range .Pages.GroupByDate "2006-01" "asc" }}
-<h3>{{ .Key }}</h3>
-<ul>
- {{ range .Pages.ByTitle }}
- <li>
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- <div class="meta">{{ .Date.Format "Mon, Jan 2, 2006" }}</div>
- </li>
- {{ end }}
-</ul>
-{{ end }}
-{{< /code >}}
-
-## Filter and Limiting Lists
-
-See the [_Lists/Filtering and Limiting Lists_
-section][filteringandlimitinglists] for details.
-
-
-[views]: /templates/views/
-[filteringandlimitinglists]: /templates/lists/#filtering-and-limiting-lists
diff --git a/content/en/templates/output-formats.md b/content/en/templates/output-formats.md
index df48d55dc..81a825493 100644
--- a/content/en/templates/output-formats.md
+++ b/content/en/templates/output-formats.md
@@ -6,7 +6,7 @@ date: 2017-03-22
publishdate: 2017-03-22
lastmod: 2019-12-11
categories: [templates]
-keywords: ["amp","outputs","rss"]
+keywords: ["amp", "outputs", "rss"]
menu:
docs:
parent: "templates"
@@ -22,7 +22,7 @@ This page describes how to properly configure your site with the media types and
## Media Types
-A [media type][] (also known as *MIME type* and *content type*) is a two-part identifier for file formats and format contents transmitted on the Internet.
+A [media type][] (also known as _MIME type_ and _content type_) is a two-part identifier for file formats and format contents transmitted on the internet.
This is the full set of built-in media types in Hugo:
@@ -30,10 +30,10 @@ This is the full set of built-in media types in Hugo:
**Note:**
-* It is possible to add custom media types or change the defaults; e.g., if you want to change the suffix for `text/html` to `asp`.
-* `Suffixes` are the values that will be used for URLs and filenames for that media type in Hugo.
-* The `Type` is the identifier that must be used when defining new/custom `Output Formats` (see below).
-* The full set of media types will be registered in Hugo's built-in development server to make sure they are recognized by the browser.
+- It is possible to add custom media types or change the defaults; e.g., if you want to change the suffix for `text/html` to `asp`.
+- `Suffixes` are the values that will be used for URLs and filenames for that media type in Hugo.
+- The `Type` is the identifier that must be used when defining new/custom `Output Formats` (see below).
+- The full set of media types will be registered in Hugo's built-in development server to make sure they are recognized by the browser.
To add or modify a media type, define it in a `mediaTypes` section in your [site configuration][config], either for all sites or for a given language.
@@ -70,9 +70,9 @@ This is the full set of Hugo's built-in output formats:
{{< datatable "output" "formats" "name" "mediaType" "path" "baseName" "rel" "protocol" "isPlainText" "isHTML" "noUgly" "permalinkable" >}}
-* A page can be output in as many output formats as you want, and you can have an infinite amount of output formats defined **as long as they resolve to a unique path on the file system**. In the above table, the best example of this is `AMP` vs. `HTML`. `AMP` has the value `amp` for `Path` so it doesn't overwrite the `HTML` version; e.g. we can now have both `/index.html` and `/amp/index.html`.
-* The `MediaType` must match the `Type` of an already defined media type.
-* You can define new output formats or redefine built-in output formats; e.g., if you want to put `AMP` pages in a different path.
+- A page can be output in as many output formats as you want, and you can have an infinite amount of output formats defined **as long as they resolve to a unique path on the file system**. In the above table, the best example of this is `AMP` vs. `HTML`. `AMP` has the value `amp` for `Path` so it doesn't overwrite the `HTML` version; e.g. we can now have both `/index.html` and `/amp/index.html`.
+- The `MediaType` must match the `Type` of an already defined media type.
+- You can define new output formats or redefine built-in output formats; e.g., if you want to put `AMP` pages in a different path.
To add or modify an output format, define it in an `outputFormats` section in your site's [configuration file](/getting-started/configuration/), either for all sites or for a given language.
@@ -118,7 +118,7 @@ The following is the full list of configuration options for output formats and t
: used to turn off ugly URLs If `uglyURLs` is set to `true` in your site. **Default:** `false`.
`notAlternative`
-: enable if it doesn't make sense to include this format in an `AlternativeOutputFormats` format listing on `Page` (e.g., with `CSS`). Note that we use the term *alternative* and not *alternate* here, as it does not necessarily replace the other format. **Default:** `false`.
+: enable if it doesn't make sense to include this format in an `AlternativeOutputFormats` format listing on `Page` (e.g., with `CSS`). Note that we use the term _alternative_ and not _alternate_ here, as it does not necessarily replace the other format. **Default:** `false`.
`permalinkable`
: make `.Permalink` and `.RelPermalink` return the rendering Output Format rather than main ([see below](#link-to-output-formats)). This is enabled by default for `HTML` and `AMP`. **Default:** `false`.
@@ -128,18 +128,19 @@ The following is the full list of configuration options for output formats and t
## Output Formats for Pages
-A `Page` in Hugo can be rendered to multiple *output formats* on the file
+A `Page` in Hugo can be rendered to multiple _output formats_ on the file
system.
### Default Output Formats
+
Every `Page` has a [`Kind`][page_kinds] attribute, and the default Output
Formats are set based on that.
-| Kind | Default Output Formats |
-|--------------- |----------------------- |
-| `page` | HTML |
-| `home` | HTML, RSS |
-| `section` | HTML, RSS |
+| Kind | Default Output Formats |
+| ---------- | ---------------------- |
+| `page` | HTML |
+| `home` | HTML, RSS |
+| `section` | HTML, RSS |
| `taxonomy` | HTML, RSS |
| `term` | HTML, RSS |
@@ -157,12 +158,8 @@ Example from site config file:
page = ["HTML"]
{{</ code-toggle >}}
-
-Note that in the above examples, the *output formats* for `section`,
-`taxonomy` and `term` will stay at their default value `["HTML",
-"RSS"]`.
-
-{{< new-in "0.73.0" >}} We have fixed the before confusing page kinds used for taxonomies (see the listing below) to be in line with the terms used when we talk about taxonomies. We have been careful to avoid site breakage, and you should get an ERROR in the console if you need to adjust your `outputs` section.
+Note that in the above examples, the _output formats_ for `section`,
+`taxonomy` and `term` will stay at their default value `["HTML", "RSS"]`.
{{% page-kinds %}}
@@ -183,7 +180,7 @@ outputs:
---
```
-## List Output formats
+## List Output formats
Each `Page` has both an `.OutputFormats` (all formats, including the current) and an `.AlternativeOutputFormats` variable, the latter of which is useful for creating a `link rel` list in your site's `<head>`:
@@ -207,7 +204,7 @@ __from `single.json.json`:__
In order for them to return the output format of the current template file instead, the given output format should have its `permalinkable` setting set to true.
-__Same template file as above with json output format's `permalinkable` set to true:__
+**Same template file as above with json output format's `permalinkable` set to true:**
```go-html-template
{{ .RelPermalink }} > /that-page/index.json
@@ -231,7 +228,7 @@ A new output format needs a corresponding template in order to render anything u
The key distinction for Hugo versions 0.20 and newer is that Hugo looks at an output format's `Name` and MediaType's `Suffixes` when choosing the template used to render a given `Page`.
{{% /note %}}
-The following table shows examples of different output formats, the suffix used, and Hugo's respective template [lookup order][]. All of the examples in the table can:
+The following table shows examples of different output formats, the suffix used, and Hugo's respective template [lookup order][]. All the examples in the table can:
* Use a [base template][base].
* Include [partial templates][partials]
@@ -242,13 +239,13 @@ Hugo will now also detect the media type and output format of partials, if possi
Hugo will look for the name given, so you can name it whatever you want. But if you want it treated as plain text, you should use the file suffix and, if needed, the name of the Output Format. The pattern is as follows:
-```
+```go-html-template
[partial name].[OutputFormat].[suffix]
```
The partial below is a plain text template (Output Format is `CSV`, and since this is the only output format with the suffix `csv`, we don't need to include the Output Format's `Name`):
-```
+```go-html-template
{{ partial "mytextpartial.csv" . }}
```
diff --git a/content/en/templates/pagination.md b/content/en/templates/pagination.md
index d89735f7c..dc56c18c4 100644
--- a/content/en/templates/pagination.md
+++ b/content/en/templates/pagination.md
@@ -4,7 +4,6 @@ linktitle: Pagination
description: Hugo supports pagination for your homepage, section pages, and taxonomies.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [templates]
keywords: [lists,sections,pagination]
menu:
@@ -13,7 +12,6 @@ menu:
weight: 140
weight: 140
sections_weight: 140
-draft: false
aliases: [/extras/pagination,/doc/pagination/]
toc: true
---
@@ -60,7 +58,7 @@ The global page size setting (`Paginate`) can be overridden by providing a posit
It is also possible to use the `GroupBy` functions in combination with pagination:
-```
+```go-html-template
{{ range (.Paginate (.Pages.GroupByDate "2006")).PageGroups }}
```
@@ -70,7 +68,7 @@ The `.Paginator` contains enough information to build a paginator interface.
The easiest way to add this to your pages is to include the built-in template (with `Bootstrap`-compatible styles):
-```
+```go-html-template
{{ template "_internal/pagination.html" . }}
```
@@ -80,7 +78,7 @@ If you use any filters or ordering functions to create your `.Paginator` *and* y
The following example shows how to create `.Paginator` before its used:
-```
+```go-html-template
{{ $paginator := .Paginate (where .Pages "Type" "posts") }}
{{ template "_internal/pagination.html" . }}
{{ range $paginator.Pages }}
@@ -90,7 +88,7 @@ The following example shows how to create `.Paginator` before its used:
Without the `where` filter, the above example is even simpler:
-```
+```go-html-template
{{ template "_internal/pagination.html" . }}
{{ range .Paginator.Pages }}
{{ .Title }}
@@ -145,14 +143,13 @@ If you want to build custom navigation, you can do so using the `.Paginator` obj
The pages are built on the following form (`BLANK` means no value):
-```
+```txt
[SECTION/TAXONOMY/BLANK]/index.html
[SECTION/TAXONOMY/BLANK]/page/1/index.html => redirect to [SECTION/TAXONOMY/BLANK]/index.html
[SECTION/TAXONOMY/BLANK]/page/2/index.html
....
```
-
[`first`]: /functions/first/
[`last`]: /functions/last/
[`after`]: /functions/after/
diff --git a/content/en/templates/partials.md b/content/en/templates/partials.md
index 56a676d7e..b3826d56d 100644
--- a/content/en/templates/partials.md
+++ b/content/en/templates/partials.md
@@ -78,7 +78,7 @@ This means the partial will *only* be able to access those variables. The partia
## Returning a value from a Partial
-In addition to outputting markup, partials can be used to return a value of any type. In order to return a value, a partial must include a lone `return` statement _at the end of the partial_.
+In addition to outputting markup, partials can be used to return a value of any type. In order to return a value, a partial must include a lone `return` statement *at the end of the partial*.
### Example GetFeatured
@@ -121,8 +121,6 @@ Only one `return` statement is allowed per partial file.
## Inline Partials
-{{< new-in "0.74.0" >}}
-
You can also define partials inline in the template. But remember that template namespace is global, so you need to make sure that the names are unique to avoid conflicts.
```go-html-template
diff --git a/content/en/templates/render-hooks.md b/content/en/templates/render-hooks.md
index 6987819ca..6fae36ad9 100644
--- a/content/en/templates/render-hooks.md
+++ b/content/en/templates/render-hooks.md
@@ -13,31 +13,31 @@ menu:
weight: 20
---
-{{< new-in "0.62.0" >}} Note that this is only supported with the [Goldmark](/getting-started/configuration-markup#goldmark) renderer.
-
+Note that this is only supported with the [Goldmark](/getting-started/configuration-markup#goldmark) renderer.
You can override certain parts of the default Markdown rendering to HTML by creating templates with base names `render-{kind}` in `layouts/_default/_markup`.
-You can also create type/section specific hooks in `layouts/[type/section]/_markup`, e.g.: `layouts/blog/_markup`.{{< new-in "0.71.0" >}}
+You can also create type/section specific hooks in `layouts/[type/section]/_markup`, e.g.: `layouts/blog/_markup`.
The hook kinds currently supported are:
* `image`
* `link`
-* `heading` {{< new-in "0.71.0" >}}
+* `heading`
* `codeblock`{{< new-in "0.93.0" >}}
You can define [Output-Format-](/templates/output-formats) and [language-](/content-management/multilingual/)specific templates if needed. Your `layouts` folder may look like this:
-```goat { class="black f7" }
-layouts
-└── _default
- └── _markup
+```text
+layouts/
+└── _default/
+ └── _markup/
+ ├── render-codeblock-bash.html
+ ├── render-codeblock.html
+ ├── render-heading.html
├── render-image.html
├── render-image.rss.xml
└── render-link.html
- └── render-codeblock.html
- └── render-codeblock-bash.html
```
Some use cases for the above:
@@ -83,10 +83,10 @@ Text
PlainText
: The plain variant of the above.
-Attributes (map) {{< new-in "0.82.0" >}}
+Attributes (map)
: A map of attributes (e.g. `id`, `class`)
-### Link with title Markdown example:
+### Link with title Markdown example
```md
[Text](https://www.gohugo.io "Title")
@@ -98,10 +98,10 @@ Here is a code example for how the render-link.html template could look:
<a href="{{ .Destination | safeURL }}"{{ with .Title}} title="{{ . }}"{{ end }}{{ if strings.HasPrefix .Destination "http" }} target="_blank" rel="noopener"{{ end }}>{{ .Text | safeHTML }}</a>
{{< /code >}}
-### Image Markdown example:
+### Image Markdown example
```md
-![Text](https://d33wubrfki0l68.cloudfront.net/c38c7334cc3f23585738e40334284fddcaf03d5e/2e17c/images/hugo-logo-wide.svg "Title")
+![Text](https://gohugo.io/images/hugo-logo-wide.svg "Title")
```
Here is a code example for how the render-image.html template could look:
@@ -146,7 +146,7 @@ layouts
└── render-codeblock-bash.html
```
-The default behaviour for these code blocks is to do [Code Highlighting](/content-management/syntax-highlighting/#highlighting-in-code-fences), but since you can pass attributes to these code blocks, they can be used for almost anything. One example would be the built-in [GoAT Diagrams](/content-management/diagrams/#goat-diagrams-ascii) or this [Mermaid Diagram Code Block Hook](/content-management/diagrams/#mermaid-diagrams) example.
+The default behavior for these code blocks is to do [Code Highlighting](/content-management/syntax-highlighting/#highlighting-in-code-fences), but since you can pass attributes to these code blocks, they can be used for almost anything. One example would be the built-in [GoAT Diagrams](/content-management/diagrams/#goat-diagrams-ascii) or this [Mermaid Diagram Code Block Hook](/content-management/diagrams/#mermaid-diagrams) example.
The context (the ".") you receive in a code block template contains:
diff --git a/content/en/templates/rss.md b/content/en/templates/rss.md
index 009ba241a..28ccafa56 100644
--- a/content/en/templates/rss.md
+++ b/content/en/templates/rss.md
@@ -57,7 +57,7 @@ copyright = "This work is licensed under a Creative Commons Attribution-ShareAli
This is the default RSS template that ships with Hugo:
-https://github.com/gohugoio/hugo/blob/master/tpl/tplimpl/embedded/templates/_default/rss.xml
+<https://github.com/gohugoio/hugo/blob/master/tpl/tplimpl/embedded/templates/_default/rss.xml>
## Reference your RSS Feed in `<head>`
diff --git a/content/en/templates/section-templates.md b/content/en/templates/section-templates.md
index a40e2a2d7..3cb37b111 100644
--- a/content/en/templates/section-templates.md
+++ b/content/en/templates/section-templates.md
@@ -70,7 +70,7 @@ Examples:
The `.Site.GetPage` example that follows assumes the following project directory structure:
-```
+```txt
.
└── content
├── blog
@@ -85,29 +85,28 @@ The `.Site.GetPage` example that follows assumes the following project directory
`.Site.GetPage` will return `nil` if no `_index.md` page is found. Therefore, if `content/blog/_index.md` does not exist, the template will output the section name:
-```
+```go-html-template
<h1>{{ with .Site.GetPage "section" "blog" }}{{ .Title }}{{ end }}</h1>
```
Since `blog` has a section index page with front matter at `content/blog/_index.md`, the above code will return the following result:
-```
+```html
<h1>My Hugo Blog</h1>
```
If we try the same code with the `events` section, however, Hugo will default to the section title because there is no `content/events/_index.md` from which to pull content and front matter:
-```
+```go-html-template
<h1>{{ with .Site.GetPage "section" "events" }}{{ .Title }}{{ end }}</h1>
```
Which then returns the following:
-```
+```html
<h1>Events</h1>
```
-
[contentorg]: /content-management/organization/
[getpage]: /functions/getpage/
[lists]: /templates/lists/
diff --git a/content/en/templates/shortcode-templates.md b/content/en/templates/shortcode-templates.md
index 839032800..15accbe7a 100644
--- a/content/en/templates/shortcode-templates.md
+++ b/content/en/templates/shortcode-templates.md
@@ -18,7 +18,7 @@ aliases: []
toc: true
---
-Shortcodes are a means to consolidate templating into small, reusable snippets that you can embed directly inside of your content. In this sense, you can think of shortcodes as the intermediary between [page and list templates][templates] and [basic content files][].
+Shortcodes are a means to consolidate templating into small, reusable snippets that you can embed directly inside your content. In this sense, you can think of shortcodes as the intermediary between [page and list templates][templates] and [basic content files][].
{{% note %}}
Hugo also ships with built-in shortcodes for common use cases. (See [Content Management: Shortcodes](/content-management/shortcodes/).)
@@ -36,7 +36,7 @@ To create a shortcode, place an HTML template in the `layouts/shortcodes` direct
You can organize your shortcodes in subfolders, e.g. in `layouts/shortcodes/boxes`. These shortcodes would then be accessible with their relative path, e.g:
-```
+```go-html-template
{{</* boxes/square */>}}
```
@@ -69,47 +69,50 @@ All shortcode parameters can be accessed via the `.Get` method. Whether you pass
To access a parameter by name, use the `.Get` method followed by the named parameter as a quoted string:
-```
+```go-html-template
{{ .Get "class" }}
```
To access a parameter by position, use the `.Get` followed by a numeric position, keeping in mind that positional parameters are zero-indexed:
-```
+```go-html-template
{{ .Get 0 }}
```
-For the second position, you would just use:
+For the second position, you would just use:
-```
+```go-html-template
{{ .Get 1 }}
```
`with` is great when the output depends on a parameter being set:
-```
+```go-html-template
{{ with .Get "class" }} class="{{ . }}"{{ end }}
```
`.Get` can also be used to check if a parameter has been provided. This is
most helpful when the condition depends on either of the values, or both:
-```
+```go-html-template
{{ if or (.Get "title") (.Get "alt") }} alt="{{ with .Get "alt" }}{{ . }}{{ else }}{{ .Get "title" }}{{ end }}"{{ end }}
```
#### `.Inner`
-If a closing shortcode is used, the `.Inner` variable will be populated with all of the content between the opening and closing shortcodes. If a closing shortcode is required, you can check the length of `.Inner` as an indicator of its existence.
+If a closing shortcode is used, the `.Inner` variable will be populated with the content between the opening and closing shortcodes. If a closing shortcode is required, you can check the length of `.Inner` as an indicator of its existence.
-A shortcode with content declared via the `.Inner` variable can also be declared without the
-content and without the closing
-by using the self-closing syntax:
+A shortcode with content declared via the `.Inner` variable can also be declared without the content and without the closing by using the self-closing syntax:
-```
+```go-html-template
{{</* innershortcode /*/>}}
```
+{{% warning %}}
+Any shortcode that refers to `.Inner` must be closed or self-closed.
+
+{{% /warning %}}
+
#### `.Params`
The `.Params` variable in shortcodes contains the list parameters passed to shortcode for more complicated use cases. You can also access higher-scoped parameters with the following logic:
@@ -129,13 +132,13 @@ The `.IsNamedParams` variable checks whether the shortcode declaration uses name
For example, you could create an `image` shortcode that can take either a `src` named parameter or the first positional parameter, depending on the preference of the content's author. Let's assume the `image` shortcode is called as follows:
-```
+```go-html-template
{{</* image src="images/my-image.jpg" */>}}
```
You could then include the following as part of your shortcode templating:
-```
+```go-html-template
{{ if .IsNamedParams }}
<img src="{{ .Get "src" }}" alt="">
{{ else }}
@@ -163,9 +166,9 @@ The following are examples of the different types of shortcodes you can create v
### Single-word Example: `year`
-Let's assume you would like to keep mentions of your copyright year current in your content files without having to continually review your markdown. Your goal is to be able to call the shortcode as follows:
+Let's assume you would like to keep mentions of your copyright year current in your content files without having to continually review your Markdown. Your goal is to be able to call the shortcode as follows:
-```
+```go-html-template
{{</* year */>}}
```
@@ -175,9 +178,9 @@ Let's assume you would like to keep mentions of your copyright year current in y
### Single Positional Example: `youtube`
-Embedded videos are a common addition to markdown content that can quickly become unsightly. The following is the code used by [Hugo's built-in YouTube shortcode][youtubeshortcode]:
+Embedded videos are a common addition to Markdown content that can quickly become unsightly. The following is the code used by [Hugo's built-in YouTube shortcode][youtubeshortcode]:
-```
+```go-html-template
{{</* youtube 09jf3ow9jfw */>}}
```
@@ -244,7 +247,7 @@ Would be rendered as:
### Single Flexible Example: `vimeo`
-```
+```go-html-template
{{</* vimeo 49718712 */>}}
{{</* vimeo id="49718712" class="flex-video" */>}}
```
@@ -288,7 +291,7 @@ The following is taken from `highlight`, which is a [built-in shortcode][] that
The template for the `highlight` shortcode uses the following code, which is already included in Hugo:
-```
+```go-html-template
{{ .Get 0 | highlight .Inner }}
```
@@ -326,7 +329,7 @@ You also have an `img` shortcode with a single named `src` parameter that you wa
You can then call your shortcode in your content as follows:
-```
+```go-html-template
{{</* gallery class="content-gallery" */>}}
{{</* img src="/images/one.jpg" */>}}
{{</* img src="/images/two.jpg" */>}}
@@ -336,7 +339,7 @@ You can then call your shortcode in your content as follows:
This will output the following HTML. Note how the first two `img` shortcodes inherit the `class` value of `content-gallery` set with the call to the parent `gallery`, whereas the third `img` only uses `src`:
-```
+```html
<div class="content-gallery">
<img src="/images/one.jpg" class="content-gallery-image">
<img src="/images/two.jpg" class="content-gallery-image">
@@ -344,7 +347,6 @@ This will output the following HTML. Note how the first two `img` shortcodes inh
<img src="/images/three.jpg">
```
-
## Error Handling in Shortcodes
Use the [errorf](/functions/errorf) template func and [.Position](/variables/shortcodes/) variable to get useful error messages in shortcodes:
@@ -366,12 +368,9 @@ ERROR 2018/11/07 10:05:55 missing value for param name: "/Users/bep/dev/go/gohug
More shortcode examples can be found in the [shortcodes directory for spf13.com][spfscs] and the [shortcodes directory for the Hugo docs][docsshortcodes].
-
## Inline Shortcodes
-{{< new-in "0.52" >}}
-
-Since Hugo 0.52, you can implement your shortcodes inline -- e.g. where you use them in the content file. This can be useful for scripting that you only need in one place.
+You can also implement your shortcodes inline -- e.g. where you use them in the content file. This can be useful for scripting that you only need in one place.
This feature is disabled by default, but can be enabled in your site config:
@@ -398,7 +397,6 @@ The same inline shortcode can be reused later in the same content file, with dif
```go-text-template
{{</* time.inline /*/>}}
```
-
[basic content files]: /content-management/formats/ "See how Hugo leverages markdown--and other supported formats--to create content for your website."
[built-in shortcode]: /content-management/shortcodes/
diff --git a/content/en/templates/taxonomy-templates.md b/content/en/templates/taxonomy-templates.md
index 27fadb85b..9c283dfc3 100644
--- a/content/en/templates/taxonomy-templates.md
+++ b/content/en/templates/taxonomy-templates.md
@@ -150,7 +150,7 @@ Weights of zero are thus treated specially: if two pages have unequal weights, a
Content can be assigned weight for each taxonomy that it's assigned to.
-```
+```txt
+++
tags = [ "a", "b", "c" ]
tags_weight = 22
diff --git a/content/en/templates/template-debugging.md b/content/en/templates/template-debugging.md
index 0a5150a8a..ef8e205da 100644
--- a/content/en/templates/template-debugging.md
+++ b/content/en/templates/template-debugging.md
@@ -1,10 +1,8 @@
---
title: Template Debugging
-# linktitle: Template Debugging
description: You can use Go templates' `printf` function to debug your Hugo templates. These snippets provide a quick and easy visualization of the variables available to you in different contexts.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [templates]
keywords: [debugging,troubleshooting]
menu:
@@ -13,43 +11,38 @@ menu:
weight: 180
weight: 180
sections_weight: 180
-draft: false
aliases: []
toc: false
---
Here are some snippets you can add to your template to answer some common questions.
-These snippets use the `printf` function available in all Go templates. This function is an alias to the Go function, [fmt.Printf](https://golang.org/pkg/fmt/).
+These snippets use the `printf` function available in all Go templates. This function is an alias to the Go function, [fmt.Printf](https://pkg.go.dev/fmt).
## What Variables are Available in this Context?
You can use the template syntax, `$.`, to get the top-level template context from anywhere in your template. This will print out all the values under, `.Site`.
-```
+```go-html-template
{{ printf "%#v" $.Site }}
```
This will print out the value of `.Permalink`:
-
-```
+```go-html-template
{{ printf "%#v" .Permalink }}
```
-
This will print out a list of all the variables scoped to the current context
(`.`, aka ["the dot"][tempintro]).
-
-```
+```go-html-template
{{ printf "%#v" . }}
```
-
When developing a [homepage][], what does one of the pages you're looping through look like?
-```
+```go-html-template
{{ range .Pages }}
{{/* The context, ".", is now each one of the pages as it goes through the loop */}}
{{ printf "%#v" . }}
@@ -60,13 +53,13 @@ When developing a [homepage][], what does one of the pages you're looping throug
Check that you are passing variables in the `partial` function:
-```
+```go-html-template
{{ partial "header.html" }}
```
This example will render the header partial, but the header partial will not have access to any contextual variables. You need to pass variables explicitly. For example, note the addition of ["the dot"][tempintro].
-```
+```go-html-template
{{ partial "header.html" . }}
```
diff --git a/content/en/templates/views.md b/content/en/templates/views.md
index 87f66afe0..495f701bd 100644
--- a/content/en/templates/views.md
+++ b/content/en/templates/views.md
@@ -29,7 +29,7 @@ The following are common use cases for content views:
To create a new view, create a template in each of your different content type directories with the view name. The following example contains an "li" view and a "summary" view for the `posts` and `project` content types. As you can see, these sit next to the [single content view][single] template, `single.html`. You can even provide a specific view for a given type and continue to use the `_default/single.html` for the primary view.
-```
+```txt
▾ layouts/
▾ posts/
li.html
@@ -44,7 +44,7 @@ To create a new view, create a template in each of your different content type d
Hugo also has support for a default content template to be used in the event that a specific content view template has not been provided for that type. Content views can also be defined in the `_default` directory and will work the same as list and single templates who eventually trickle down to the `_default` directory as a matter of the lookup order.
-```
+```txt
▾ layouts/
▾ _default/
li.html
@@ -63,7 +63,7 @@ The following is the [lookup order][lookup] for content views:
## Example: Content View Inside a List
-The following example demonstrates how to use content views inside of your [list templates][lists].
+The following example demonstrates how to use content views inside your [list templates][lists].
### `list.html`
diff --git a/content/en/tools/_index.md b/content/en/tools/_index.md
index a186ffb06..a63041819 100644
--- a/content/en/tools/_index.md
+++ b/content/en/tools/_index.md
@@ -13,7 +13,6 @@ menu:
weight: 01
weight: 01
sections_weight: 01
-draft: false
---
One of Hugo's greatest strengths is its passionate---and always evolving---developer community. With the exception of the `highlight` shortcode mentioned in [Syntax Highlighting][syntax], the tools and other projects featured in this section are offerings from both commercial services and open-source projects, many of which are developed by Hugo developers just like you.
diff --git a/content/en/tools/editors.md b/content/en/tools/editors.md
index 8da5fc2d7..ed67885fc 100644
--- a/content/en/tools/editors.md
+++ b/content/en/tools/editors.md
@@ -4,7 +4,6 @@ linktitle: Editor Plug-ins
description: The Hugo community uses a wide range of preferred tools and has developed plug-ins for some of the most popular text editors to help automate parts of your workflow.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [developer tools]
keywords: [editor, plug-ins]
menu:
@@ -31,12 +30,13 @@ The Hugo community uses a wide range of preferred tools and has developed plug-i
* [Hugo Helper](https://marketplace.visualstudio.com/items?itemName=rusnasonov.vscode-hugo). Hugo Helper is a plugin for Visual Studio Code that has some useful commands for Hugo. The source code can be found [here](https://github.com/rusnasonov/vscode-hugo).
* [Hugo Language and Syntax Support](https://marketplace.visualstudio.com/items?itemName=budparr.language-hugo-vscode). Hugo Language and Syntax Support is a Visual Studio Code plugin for Hugo syntax highlighting and snippets. The source code can be found [here](https://github.com/budparr/language-hugo-vscode).
* [Hugo Themer](https://marketplace.visualstudio.com/items?itemName=eliostruyf.vscode-hugo-themer). Hugo Themer is an extension to help you while developing themes. It allows you to easily navigate through your theme files.
-* [Front Matter](https://marketplace.visualstudio.com/items?itemName=eliostruyf.vscode-front-matter). Once you go for a static site, you need to think about how you are going to manage your articles. Front matter is a tool that helps you maintaining the metadata/front matter of your articles like: creation date, modified date, slug, tile, SEO check, and many more...
+* [Front Matter](https://marketplace.visualstudio.com/items?itemName=eliostruyf.vscode-front-matter). Once you go for a static site, you need to think about how you are going to manage your articles. Front matter is a tool that helps you maintain the metadata/front matter of your articles like: creation date, modified date, slug, tile, SEO check, and many more...
+* [Syntax Highlighting for Hugo Shortcodes](https://marketplace.visualstudio.com/items?itemName=kaellarkin.hugo-shortcode-syntax). This extension add some syntax highlighting for Shortcodes, making visual identification of individual pieces easier.
## Emacs
* [emacs-easy-hugo](https://github.com/masasam/emacs-easy-hugo). Emacs major mode for managing hugo blogs. Note that Hugo also supports [Org-mode][formats].
-* [ox-hugo.el](https://ox-hugo.scripter.co). Native Org-mode exporter that exports to Blackfriday Markdown with Hugo front-matter. `ox-hugo` supports two common Org blogging flows --- exporting multiple Org sub-trees in a single file to multiple Hugo posts, and exporting a single Org file to a single Hugo post. It also leverages the Org tag and property inheritance features. See [*Why ox-hugo?*](https://ox-hugo.scripter.co/doc/why-ox-hugo/) for more.
+* [ox-hugo.el](https://ox-hugo.scripter.co). Native Org-mode exporter that exports to Blackfriday Markdown with Hugo front-matter. `ox-hugo` supports two common Org blogging flows --- exporting multiple Org subtrees in a single file to multiple Hugo posts, and exporting a single Org file to a single Hugo post. It also leverages the Org tag and property inheritance features. See [*Why ox-hugo?*](https://ox-hugo.scripter.co/doc/why-ox-hugo/) for more.
## Vim
diff --git a/content/en/tools/frontends.md b/content/en/tools/frontends.md
index b0fb03632..9f52c4c67 100644
--- a/content/en/tools/frontends.md
+++ b/content/en/tools/frontends.md
@@ -6,7 +6,7 @@ date: 2017-02-01
publishdate: 2017-02-01
lastmod: 2017-02-01
categories: [developer tools]
-keywords: [frontend,gui]
+keywords: [frontend, gui]
menu:
docs:
parent: "tools"
@@ -18,15 +18,13 @@ aliases: []
toc: false
---
-* [enwrite](https://github.com/zzamboni/enwrite). Enwrite enables evernote-powered, statically generated blogs and websites. Now posting to your blog or updating your website is as easy as writing a new note in Evernote!
-* [Lipi](https://github.com/SohanChy/Lipi). Lipi is a native GUI frontend written in Java to manage your Hugo websites.
-* [Netlify CMS](https://netlifycms.org). Netlify CMS is an open source, serverless solution for managing Git based content in static sites, and it works on any platform that can host static sites. A [Hugo/Netlify CMS starter](https://github.com/netlify-templates/one-click-hugo-cms) is available to get new projects running quickly.
-* [Hokus CMS](https://github.com/julianoappelklein/hokus). Hokus CMS is an open source, multi-platform, easy to use, desktop application for Hugo. Build from simple to complex user interfaces for Hugo websites by choosing from a dozen ready-to-use components — all for free, with no vendor lock-in.
-
+- [enwrite](https://github.com/zzamboni/enwrite). Enwrite enables evernote-powered, statically generated blogs and websites. Now posting to your blog or updating your website is as easy as writing a new note in Evernote!
+- [Lipi](https://github.com/SohanChy/Lipi). Lipi is a native GUI frontend written in Java to manage your Hugo websites.
+- [Netlify CMS](https://netlifycms.org). Netlify CMS is an open source, serverless solution for managing Git based content in static sites, and it works on any platform that can host static sites. A [Hugo/Netlify CMS starter](https://github.com/netlify-templates/one-click-hugo-cms) is available to get new projects running quickly.
+- [Hokus CMS](https://github.com/julianoappelklein/hokus). Hokus CMS is an open source, multi-platform, easy to use, desktop application for Hugo. Build from simple to complex user interfaces for Hugo websites by choosing from a dozen ready-to-use components — all for free, with no vendor lock-in.
## Commercial Services
-* [DATOCMS](https://www.datocms.com) DatoCMS is a fully customizable administrative area for your static websites. Use your favorite website generator, let your clients publish new content independently, and the host the site anywhere you like.
-* [Forestry.io](https://forestry.io/). Forestry is a git-backed CMS for Hugo, Gatsby, Jekyll and VuePress websites with support for GitHub, GitLab, Bitbucket and Azure Devops. Forestry provides a nice user interface to edit and model content for non technical editors. It supports S3, Cloudinary and Netlify Large Media integrations for storing media. Every time an update is made via the CMS, Forestry will commit changes back to your repo and vice-versa.
-* [CloudCannon](https://cloudcannon.com/hugo-cms/). The intuitive Git-based CMS for your Hugo website. CloudCannon syncs changes from your Git repository and pushes content changes back, so your development and content teams are always in sync. Edit all of your content on the page with visual editing, build entire pages with reusable custom components and then publish confidently.
-
+- [DATOCMS](https://www.datocms.com) DatoCMS is a fully customizable administrative area for your static websites. Use your favorite website generator, let your clients publish new content independently, and the host the site anywhere you like.
+- [Forestry.io](https://forestry.io/). Forestry is a git-backed CMS for Hugo, Gatsby, Jekyll and VuePress websites with support for GitHub, GitLab, Bitbucket and Azure Devops. Forestry provides a nice user interface to edit and model content for non technical editors. It supports S3, Cloudinary and Netlify Large Media integrations for storing media. Every time an update is made via the CMS, Forestry will commit changes back to your repo and vice-versa.
+- [CloudCannon](https://cloudcannon.com/hugo-cms/). The intuitive Git-based CMS for your Hugo website. CloudCannon syncs changes from your Git repository and pushes content changes back, so your development and content teams are always in sync. Edit all of your content on the page with visual editing, build entire pages with reusable custom components and then publish confidently.
diff --git a/content/en/tools/migrations.md b/content/en/tools/migrations.md
index 7009164eb..d6ca14ab5 100644
--- a/content/en/tools/migrations.md
+++ b/content/en/tools/migrations.md
@@ -5,7 +5,7 @@ description: A list of community-developed tools for migrating from your existin
date: 2017-02-01
publishdate: 2017-02-01
lastmod: 2022-03-26
-keywords: [migrations,jekyll,wordpress,drupal,ghost,contentful]
+keywords: [migrations, jekyll, wordpress, drupal, ghost, contentful]
menu:
docs:
parent: "tools"
@@ -13,7 +13,7 @@ menu:
weight: 10
sections_weight: 10
draft: false
-aliases: [/developer-tools/migrations/,/developer-tools/migrated/]
+aliases: [/developer-tools/migrations/, /developer-tools/migrated/]
toc: true
---
@@ -29,7 +29,7 @@ Take a look at this list of migration tools if you currently use other blogging
Alternatively, you can use the new [Jekyll import command](/commands/hugo_import_jekyll/).
-- [JekyllToHugo](https://github.com/SenjinDarashiva/JekyllToHugo) - A Small script for converting Jekyll blog posts to a Hugo site.
+- [JekyllToHugo](https://github.com/fredrikloch/JekyllToHugo) - A Small script for converting Jekyll blog posts to a Hugo site.
- [ConvertToHugo](https://github.com/coderzh/ConvertToHugo) - Convert your blog from Jekyll to Hugo.
## Ghost
@@ -49,7 +49,6 @@ Alternatively, you can use the new [Jekyll import command](/commands/hugo_import
- [wordpress-to-hugo-exporter](https://github.com/SchumacherFM/wordpress-to-hugo-exporter) - A one-click WordPress plugin that converts all posts, pages, taxonomies, metadata, and settings to Markdown and YAML which can be dropped into Hugo. (Note: If you have trouble using this plugin, you can [export your site for Jekyll](https://wordpress.org/plugins/jekyll-exporter/) and use Hugo's built in Jekyll converter listed above.)
- [blog2md](https://github.com/palaniraja/blog2md) - Works with [exported xml](https://en.support.wordpress.com/export/) file of your free YOUR-TLD.wordpress.com website. It also saves approved comments to `YOUR-POST-NAME-comments.md` file along with posts.
- [wordhugopress](https://github.com/nantipov/wordhugopress) - A small utility written in Java, exports the entire WordPress site from the database and resource (e.g. images) files stored locally or remotely. Therefore, migration from the backup files is possible. Supports merging of the multiple WordPress sites into a single Hugo one.
-- [wpxr-to-static](https://github.com/danielfdickinson/wpxr-to-static) - WordPress eXtended RSS to Static Generator Conversion, Python3 program to convert WordPress XML Export (WPXR) format files to Hugo Markdown files (with YAML metadata) and a `config.toml` for the site. Inspired by [exitwp-for-hugo](https://github.com/wooni005/exitwp-for-hugo) (a Python 2 \[EOL] script which works with the xml export from WordPress and converts WordPress pages and posts to Markdown and YAML for hugo).
## Medium
@@ -81,7 +80,6 @@ Alternatively, you can use the new [Jekyll import command](/commands/hugo_import
- [contentful2hugo](https://github.com/ArnoNuyts/contentful2hugo) - A tool to create content-files for Hugo from content on [Contentful](https://www.contentful.com/).
-
## BlogML
-- [BlogML2Hugo](https://github.com/jijiechen/BlogML2Hugo) - A tool that helps you convert BlogML xml file to Hugo markdown files. Users need to take care of links to attachments and images by themselves. This helps the blogs that export BlogML files (e.g. BlogEngine.NET) transform to hugo sites easily.
+- [BlogML2Hugo](https://github.com/jijiechen/BlogML2Hugo) - A tool that helps you convert BlogML xml file to Hugo Markdown files. Users need to take care of links to attachments and images by themselves. This helps the blogs that export BlogML files (e.g. BlogEngine.NET) transform to hugo sites easily.
diff --git a/content/en/tools/other.md b/content/en/tools/other.md
index 3afd7b96b..ed7c530d0 100644
--- a/content/en/tools/other.md
+++ b/content/en/tools/other.md
@@ -4,26 +4,25 @@ linktitle: Other Projects
description: Some interesting projects developed by the Hugo community that don't quite fit into our other developer tool categories.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [developer tools]
-keywords: [frontend,gui]
+keywords: [frontend, gui]
menu:
docs:
parent: "tools"
weight: 70
weight: 70
sections_weight: 70
-draft: false
aliases: []
toc: false
---
And for all the other small things around Hugo:
-* [hugo-gallery](https://github.com/icecreammatt/hugo-gallery) lets you create an image gallery for Hugo sites.
-* [flickr-hugo-embed](https://github.com/nikhilm/flickr-hugo-embed) prints shortcodes to embed a set of images from an album on Flickr into Hugo.
-* [hugo-openapispec-shortcode](https://github.com/tenfourty/hugo-openapispec-shortcode) A shortcode that allows you to include [Open API Spec](https://openapis.org) (formerly known as Swagger Spec) in a page.
-* [HugoPhotoSwipe](https://github.com/GjjvdBurg/HugoPhotoSwipe) makes it easy to create image galleries using PhotoSwipe.
-* [Hugo SFTP Upload](https://github.com/thomasmey/HugoSftpUpload) Syncs the local build of your Hugo website with your remote webserver via SFTP.
-* [Emacs Easy Hugo](https://github.com/masasam/emacs-easy-hugo) Emacs package for writing blog posts in markdown or org-mode and building your site with Hugo.
-* [JAMStack Themes](https://jamstackthemes.dev/ssg/hugo/). JAMStack themes is a collection of site themes filterable by static site generator and supported CMS to help build CMS-connected sites using Hugo (linking to Hugo-specific themes).
+- [hugo-gallery](https://github.com/icecreammatt/hugo-gallery) lets you create an image gallery for Hugo sites.
+- [flickr-hugo-embed](https://github.com/nikhilm/flickr-hugo-embed) prints shortcodes to embed a set of images from an album on Flickr into Hugo.
+- [hugo-openapispec-shortcode](https://github.com/tenfourty/hugo-openapispec-shortcode) A shortcode that allows you to include [Open API Spec](https://openapis.org) (formerly known as Swagger Spec) in a page.
+- [HugoPhotoSwipe](https://github.com/GjjvdBurg/HugoPhotoSwipe) makes it easy to create image galleries using PhotoSwipe.
+- [Hugo SFTP Upload](https://github.com/thomasmey/HugoSftpUpload) Syncs the local build of your Hugo website with your remote webserver via SFTP.
+- [Emacs Easy Hugo](https://github.com/masasam/emacs-easy-hugo) Emacs package for writing blog posts in markdown or org-mode and building your site with Hugo.
+- [JAMStack Themes](https://jamstackthemes.dev/ssg/hugo/). JAMStack themes is a collection of site themes filterable by static site generator and supported CMS to help build CMS-connected sites using Hugo (linking to Hugo-specific themes).
+- [plausible-hugo](https://github.com/divinerites/plausible-hugo). Easy Hugo integration for Plausible Analytics, a simple, open-source, lightweight and privacy-friendly web analytics alternative to Google Analytics.
diff --git a/content/en/tools/search.md b/content/en/tools/search.md
index e28e144c1..97ddeaf01 100644
--- a/content/en/tools/search.md
+++ b/content/en/tools/search.md
@@ -4,7 +4,6 @@ linktitle: Search
description: See some of the open-source and commercial search options for your newly created Hugo website.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-26
categories: [developer tools]
keywords: [search,tools]
menu:
@@ -13,7 +12,6 @@ menu:
weight: 60
weight: 60
sections_weight: 60
-draft: false
aliases: []
toc: true
---
@@ -22,11 +20,13 @@ A static website with a dynamic search function? Yes, Hugo provides an alternati
* [GitHub Gist for Hugo Workflow](https://gist.github.com/sebz/efddfc8fdcb6b480f567). This gist contains a simple workflow to create a search index for your static website. It uses a simple Grunt script to index all your content files and [lunr.js](https://lunrjs.com/) to serve the search results.
-* [hugo-lunr](https://www.npmjs.com/package/hugo-lunr). A simple way to add site search to your static Hugo site using [lunr.js](https://lunrjs.com/). Hugo-lunr will create an index file of any html and markdown documents in your Hugo project.
+* [hugo-lunr](https://www.npmjs.com/package/hugo-lunr). A simple way to add site search to your static Hugo site using [lunr.js](https://lunrjs.com/). Hugo-lunr will create an index file of any HTML and Markdown documents in your Hugo project.
* [hugo-lunr-zh](https://www.npmjs.com/package/hugo-lunr-zh). A bit like Hugo-lunr, but Hugo-lunr-zh can help you separate the Chinese keywords.
-* [Github Gist for Fuse.js integration](https://gist.github.com/eddiewebb/735feb48f50f0ddd65ae5606a1cb41ae). This gist demonstrates how to leverage Hugo's existing build time processing to generate a searchable JSON index used by [Fuse.js](https://fusejs.io/) on the client side. Although this gist uses Fuse.js for fuzzy matching, any client side search tool capable of reading JSON indexes will work. Does not require npm, grunt or other build-time tools except Hugo!
+* [GitHub Gist for Fuse.js integration](https://gist.github.com/eddiewebb/735feb48f50f0ddd65ae5606a1cb41ae). This gist demonstrates how to leverage Hugo's existing build time processing to generate a searchable JSON index used by [Fuse.js](https://fusejs.io/) on the client-side. Although this gist uses Fuse.js for fuzzy matching, any client-side search tool capable of reading JSON indexes will work. Does not require npm, grunt or other build-time tools except Hugo!
* [hugo-search-index](https://www.npmjs.com/package/hugo-search-index). A library containing Gulp tasks and a prebuilt browser script that implements search. Gulp generates a search index from project markdown files.
* [hugofastsearch](https://gist.github.com/cmod/5410eae147e4318164258742dd053993). A usability and speed update to "GitHub Gist for Fuse.js integration" — global, keyboard-optimized search.
+* [JS & Fuse.js tutorial](https://makewithhugo.com/add-search-to-a-hugo-site/) A simple client-side search solution, using FuseJS (does not require jQuery).
+* [Pagefind](https://github.com/cloudcannon/pagefind). A fully static search library that aims to perform well on large sites, while using as little of your users' bandwidth as possible.
## Commercial Search Services
diff --git a/content/en/troubleshooting/build-performance.md b/content/en/troubleshooting/build-performance.md
index 1ec564757..ea31ef84b 100644
--- a/content/en/troubleshooting/build-performance.md
+++ b/content/en/troubleshooting/build-performance.md
@@ -18,19 +18,19 @@ toc: true
## Template Metrics
Hugo is a very fast static site generator, but it is possible to write
-inefficient templates. Hugo's *template metrics* feature is extremely helpful
+inefficient templates. Hugo's _template metrics_ feature is extremely helpful
in pinpointing which templates are executed most often and how long those
executions take **in terms of CPU time**.
-| Metric Name | Description |
-|---------------------|-------------|
-| cumulative duration | The cumulative time spent executing a given template. |
-| average duration | The average time spent executing a given template. |
+| Metric Name | Description |
+| ------------------- | -------------------------------------------------------------- |
+| cumulative duration | The cumulative time spent executing a given template. |
+| average duration | The average time spent executing a given template. |
| maximum duration | The maximum time a single execution took for a given template. |
-| count | The number of times a template was executed. |
-| template | The template name. |
+| count | The number of times a template was executed. |
+| template | The template name. |
-```
+```txt
▶ hugo --templateMetrics
Started building sites ...
@@ -77,20 +77,18 @@ simultaneously. Because of this parallelism, the sum of "cumulative duration"
values is usually greater than the actual time it takes to build a site.
{{% /note %}}
-
## Cached Partials
Some `partial` templates such as sidebars or menus are executed many times
-during a site build. Depending on the content within the `partial` template and
+during a site build. Depending on the content within the `partial` template and
the desired output, the template may benefit from caching to reduce the number
-of executions. The [`partialCached`][partialCached] template function provides
+of executions. The [`partialCached`][partialcached] template function provides
caching capabilities for `partial` templates.
{{% tip %}}
Note that you can create cached variants of each `partial` by passing additional
-parameters to `partialCached` beyond the initial context. See the
+parameters to `partialCached` beyond the initial context. See the
`partialCached` documentation for more details.
{{% /tip %}}
-
[partialCached]:{{< ref "/functions/partialCached.md" >}}
diff --git a/content/en/troubleshooting/faq.md b/content/en/troubleshooting/faq.md
index c4246caf1..998f9bbbe 100644
--- a/content/en/troubleshooting/faq.md
+++ b/content/en/troubleshooting/faq.md
@@ -19,9 +19,9 @@ aliases: [/faq/]
## I can't see my content!
-Is your markdown file [in draft mode](https://gohugo.io/content-management/front-matter/#front-matter-variables)? When testing, run `hugo server` with the `-D` or `--buildDrafts` [switch](https://gohugo.io/getting-started/usage/#draft-future-and-expired-content).
+Is your Markdown file [in draft mode](https://gohugo.io/content-management/front-matter/#front-matter-variables)? When testing, run `hugo server` with the `-D` or `--buildDrafts` [switch](https://gohugo.io/getting-started/usage/#draft-future-and-expired-content).
-Is your markdown file part of a [leaf bundle](/content-management/page-bundles/)? If there is an `index.md` file in the same or any parent directory then other markdown files will not be rendered as individual pages.
+Is your Markdown file part of a [leaf bundle](/content-management/page-bundles/)? If there is an `index.md` file in the same or any parent directory then other Markdown files will not be rendered as individual pages.
## Can I set configuration variables via OS environment?
@@ -35,7 +35,9 @@ Yes you can! See [Configure with Environment Variables](/getting-started/configu
How to automate the "publish at intervals" part depends on your situation:
* If you deploy from your own PC/server, you can automate with [Cron](https://en.wikipedia.org/wiki/Cron) or similar.
-* If your site is hosted on a service similar to [Netlify](https://www.netlify.com/) you can use a service such as [ifttt](https://ifttt.com/date_and_time) to schedule the updates.
+* If your site is hosted on a service similar to [Netlify](https://www.netlify.com/) you can:
+ * Use a service such as [ifttt](https://ifttt.com/date_and_time) to schedule the updates
+ * Set up a deploy hook which you can run with a cron service to deploy your site at intervals, such as [cron-job.org](https://cron-job.org/) (both Netlify and Cloudflare Pages support deploy hooks)
Also see this Twitter thread:
@@ -49,7 +51,7 @@ Yes you can! Read [this](/hosting-and-deployment/hosting-on-netlify/#configure-h
## I get "... this feature is not available in your current Hugo version"
-If you process `SCSS` or `SASS` to `CSS` in your Hugo project with `libsass` as the transpiler or if you convert images to the `webp` format, you need the Hugo `extended` version, or else you may see an error message similar to the below:
+If you process `SCSS` or `Sass` to `CSS` in your Hugo project with `libsass` as the transpiler or if you convert images to the `webp` format, you need the Hugo `extended` version, or else you may see an error message similar to the below:
```bash
error: failed to transform resource: TOCSS: failed to transform "scss/main.scss" (text/x-scss): this feature is not available in your current Hugo version
@@ -58,14 +60,3 @@ error: failed to transform resource: TOCSS: failed to transform "scss/main.scss"
We release two set of binaries for technical reasons. The extended version is not what you get by default for some installation methods. On the [release page](https://github.com/gohugoio/hugo/releases), look for archives with `extended` in the name. To build `hugo-extended`, use `go install --tags extended`
To confirm, run `hugo version` and look for the word `extended`.
-
-## Do I need to install Git to create, deploy, and maintain a website with Hugo?
-
->Technically, no.
->
->Practically, yes.
-
-* The primary installation method documented by most (perhaps all) themes is via Git or the Hugo Modules feature.
-* The Hugo Modules feature requires Go, and Go “gets” with Git.
-* A Git repository is required by CI/CD hosting (Bitbucket, Cloudflare, GitHub Pages, GitLab Pages, Netlify, et. al.).
-* The canonical “last modified” date for content is its Git committer date; using anything else is error-prone.
diff --git a/content/en/variables/files.md b/content/en/variables/files.md
index d8f3daece..4e6c0632f 100644
--- a/content/en/variables/files.md
+++ b/content/en/variables/files.md
@@ -34,7 +34,7 @@ The `.File` object contains the following fields:
: the filename without extension or optional language identifier (e.g., `foo`)
.File.ContentBaseName
-: is a either TranslationBaseName or name of containing folder if file is a leaf bundle.
+: is either a TranslationBaseName or name of containing folder if file is a leaf bundle.
.File.BaseFileName
: the filename without extension (e.g., `foo.en`)
diff --git a/content/en/variables/git.md b/content/en/variables/git.md
index 58a285fd9..24878e350 100644
--- a/content/en/variables/git.md
+++ b/content/en/variables/git.md
@@ -53,6 +53,6 @@ The `GitInfo` object contains the following fields:
## `.Lastmod`
-If the `.GitInfo` feature is enabled, `.Lastmod` (on `Page`) is fetched from Git i.e. `.GitInfo.AuthorDate`. This behaviour can be changed by adding your own [front matter configuration for dates](/getting-started/configuration/#configure-front-matter).
+If the `.GitInfo` feature is enabled, `.Lastmod` (on `Page`) is fetched from Git i.e. `.GitInfo.AuthorDate`. This behavior can be changed by adding your own [front matter configuration for dates](/getting-started/configuration/#configure-front-matter).
[configuration]: /getting-started/configuration/
diff --git a/content/en/variables/menus.md b/content/en/variables/menus.md
index 9b8fe4d49..a59560729 100644
--- a/content/en/variables/menus.md
+++ b/content/en/variables/menus.md
@@ -40,7 +40,7 @@ Reference to the [page object][page-object] associated with the menu entry. This
will be non-nil if the menu entry is set via a page's front-matter and not via
the site config.
-.PageRef {{< new-in "0.86.0" >}}
+.PageRef
: _string_ <br /> Can be set if defined in site config and the menu entry refers to a Page. [site.GetPage](/functions/getpage/) will be used to do the page lookup. If this is set, you don't need to set the `URL`.
.Name
@@ -67,9 +67,9 @@ a string representing HTML.
.Weight
: _int_ <br />
-Value of the `weight` key if set for the menu entry. By default the entries in
-a menu are sorted ascending by their `weight`. If that key is not set, and if
-the menu entry is set in a page front-matter, this value defaults to the page's
+Value of the `weight` key if set for the menu entry. By default the entries in
+a menu are sorted ascending by their `weight`. If that key is not set, and if
+the menu entry is set in a page front-matter, this value defaults to the page's
`.Weight`.
.Parent
@@ -123,6 +123,5 @@ See [`.IsMenuCurrent` method](/functions/ismenucurrent/).
: _(menu string, menuEntry *MenuEntry) boolean_ <br />
See [`.HasMenuCurrent` method](/functions/hasmenucurrent/).
-
[menu-template]: /templates/menu-templates/
[page-object]: /variables/page/
diff --git a/content/en/variables/page.md b/content/en/variables/page.md
index df7e3cb71..78100a6af 100644
--- a/content/en/variables/page.md
+++ b/content/en/variables/page.md
@@ -4,7 +4,6 @@ linktitle:
description: Page-level variables are defined in a content file's front matter, derived from the content's file location, or extracted from the content body itself.
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
categories: [variables and params]
keywords: [pages]
draft: false
@@ -106,16 +105,16 @@ See also `.ExpiryDate`, `.Date`, `.PublishDate`, and [`.GitInfo`][gitinfo].
.Pages
: a collection of associated pages. This value will be `nil` within
- the context of regular content pages. See [`.Pages`](#pages).
+ the context of regular content pages. See [`.Pages`]({{< relref "page.md#pages" >}}).
.Permalink
: the Permanent link for this page; see [Permalinks](/content-management/urls/)
.Plain
-: the Page content stripped of HTML tags and presented as a string.
+: the Page content stripped of HTML tags and presented as a string. You may need to pipe the result through the [`htmlUnescape`](/functions/htmlunescape/) function when rendering this value with the HTML [output format](/templates/output-formats#output-format-definitions).
.PlainWords
-: the slice of strings that results from splitting .Plain into words, as defined in Go's [strings.Fields](https://golang.org/pkg/strings/#Fields).
+: the slice of strings that results from splitting .Plain into words, as defined in Go's [strings.Fields](https://pkg.go.dev/strings#Fields).
.Prev
: Points down to the previous [regular page](/variables/site/#site-pages) (sorted by Hugo's [default sort](/templates/lists#default-weight--date--linktitle--filepath)). Example: `{{if .Prev}}{{.Prev.Permalink}}{{end}}`. Calling `.Prev` from the last page returns `nil`.
@@ -201,7 +200,7 @@ aliased form `.Pages`.
Any other value defined in the front matter in a content file, including taxonomies, will be made available as part of the `.Params` variable.
-```
+```yml
---
title: My First Post
date: 2017-02-20T15:26:23-06:00
@@ -220,7 +219,7 @@ Page-level `.Params` are *only* accessible in lowercase.
The `.Params` variable is particularly useful for the introduction of user-defined front matter fields in content files. For example, a Hugo website on book reviews could have the following front matter in `/content/review/book01.md`:
-```
+```yml
---
...
affiliatelink: "http://www.my-book-link.here"
@@ -253,7 +252,7 @@ See [Archetypes](/content-management/archetypes/) for consistency of `Params` ac
In Hugo, you can declare params in individual pages and globally for your entire website. A common use case is to have a general value for the site param and a more specific value for some of the pages (i.e., a header image):
-```
+```go-html-template
{{ $.Param "header_image" }}
```
@@ -263,7 +262,7 @@ The `.Param` method provides a way to resolve a single value according to it's d
When front matter contains nested fields like the following:
-```
+```yml
---
author:
given_name: John
@@ -273,13 +272,13 @@ author:
```
`.Param` can access these fields by concatenating the field names together with a dot:
-```
+```go-html-template
{{ $.Param "author.display_name" }}
```
If your front matter contains a top-level key that is ambiguous with a nested key, as in the following case:
-```
+```yml
---
favorites.flavor: vanilla
favorites:
@@ -289,7 +288,7 @@ favorites:
The top-level key will be preferred. Therefore, the following method, when applied to the previous example, will print `vanilla` and not `chocolate`:
-```
+```txt
{{ $.Param "favorites.flavor" }}
=> vanilla
```
diff --git a/content/en/variables/pages.md b/content/en/variables/pages.md
index 79d39a158..61036dd74 100644
--- a/content/en/variables/pages.md
+++ b/content/en/variables/pages.md
@@ -23,8 +23,8 @@ Also see [List templates](/templates/lists) for an overview of sort methods.
`.Next` and `.Prev` on `Pages` work similar to the methods with the same names on `.Page`, but are more flexible (and slightly slower) as they can be used on any page collection.
-`.Next` points **up** to the next page relative to the page sent in as the argument. Example: `{{with .Site.RegularPages.Next . }}{{.RelPermalink}}{{end}}`. Calling `.Next` with the first page in the collection returns `nil`.
+`.Next` points **up** to the next page relative to the page sent in as the argument. Example: `{{with .Site.RegularPages.Next . }}{{.RelPermalink}}{{end}}`. Calling `.Next` with the first page in the collection returns `nil`.
## .Prev PAGE
-`.Prev` points **down** to the previous page relative to the page sent in as the argument. Example: `{{with .Site.RegularPages.Prev . }}{{.RelPermalink}}{{end}}`. Calling `.Prev` with the last page in the collection returns `nil`. \ No newline at end of file
+`.Prev` points **down** to the previous page relative to the page sent in as the argument. Example: `{{with .Site.RegularPages.Prev . }}{{.RelPermalink}}{{end}}`. Calling `.Prev` with the last page in the collection returns `nil`.
diff --git a/content/en/variables/shortcodes.md b/content/en/variables/shortcodes.md
index 37ae30629..a7c9e475b 100644
--- a/content/en/variables/shortcodes.md
+++ b/content/en/variables/shortcodes.md
@@ -4,10 +4,8 @@ linktitle: Shortcode Variables
description: Shortcodes can access page variables and also have their own specific built-in variables.
date: 2017-03-12
publishdate: 2017-03-12
-lastmod: 2017-03-12
categories: [variables and params]
keywords: [shortcodes]
-draft: false
menu:
docs:
parent: "variables"
@@ -47,6 +45,3 @@ toc: false
.InnerDeindent {{< new-in "0.100.0" >}}
: Gets the `.Inner` with any indentation removed. This is what's used in the built-in `{{</* highlight */>}}` shortcode.
-
-
-
diff --git a/content/en/variables/site.md b/content/en/variables/site.md
index bdfeb6527..11f37b369 100644
--- a/content/en/variables/site.md
+++ b/content/en/variables/site.md
@@ -22,7 +22,7 @@ The following is a list of site-level (aka "global") variables. Many of these va
## Get the Site object from a partial
-All the methods below, e.g. `.Site.RegularPages` can also be reached via the global [`site`](/functions/site/) function, e.g. `site.RegularPages`, which can be handy in partials where the `Page` object isn't easily available. {{< new-in "0.53" >}}.
+All the methods below, e.g. `.Site.RegularPages` can also be reached via the global [`site`](/functions/site/) function, e.g. `site.RegularPages`, which can be handy in partials where the `Page` object isn't easily available.
## Site Variables List
@@ -84,13 +84,13 @@ All the methods below, e.g. `.Site.RegularPages` can also be reached via the glo
: a string representing the date/time of the most recent change to your site. This string is based on the [`date` variable in the front matter](/content-management/front-matter) of your content pages.
.Site.Menus
-: all of the menus in the site.
+: all the menus in the site.
.Site.Pages
-: array of all content ordered by Date with the newest first. This array contains only the pages in the current language. See [`.Site.Pages`](#site-pages).
+: array of all content ordered by Date with the newest first. This array contains only the pages in the current language. See [`.Site.Pages`]({{< relref "site.md#site-pages" >}}).
.Site.RegularPages
-: a shortcut to the *regular* page collection. `.Site.RegularPages` is equivalent to `where .Site.Pages "Kind" "page"`. See [`.Site.Pages`](#site-pages).
+: a shortcut to the *regular* page collection. `.Site.RegularPages` is equivalent to `where .Site.Pages "Kind" "page"`. See [`.Site.Pages`]({{< relref "site.md#site-pages" >}}).
.Site.Sections
: top-level directories of the site.
@@ -129,7 +129,4 @@ You can use `.Site.Params` in a [partial template](/templates/partials/) to call
{{< getcontent path="readfiles/pages-vs-site-pages.md" >}}
-
-
-
[config]: /getting-started/configuration/
diff --git a/content/en/variables/sitemap.md b/content/en/variables/sitemap.md
index dd926f2b3..24700182a 100644
--- a/content/en/variables/sitemap.md
+++ b/content/en/variables/sitemap.md
@@ -4,7 +4,6 @@ linktitle: Sitemap Variables
description:
date: 2017-03-12
publishdate: 2017-03-12
-lastmod: 2017-03-12
categories: [variables and params]
keywords: [sitemap]
draft: false
@@ -29,4 +28,4 @@ A sitemap is a `Page` and therefore has all the [page variables][pagevars] avail
.Sitemap.Filename
: the sitemap filename
-[pagevars]: /variables/page/ \ No newline at end of file
+[pagevars]: /variables/page/
diff --git a/content/zh/content-management/_index.md b/content/zh/content-management/_index.md
index 8c088dc57..2f4b198c1 100644
--- a/content/zh/content-management/_index.md
+++ b/content/zh/content-management/_index.md
@@ -1,18 +1,17 @@
---
title: 内容管理
-linktitle: 内容管理概览
+linkTitle: 内容管理概览
description: Hugo 可以管理大型的静态网站,支持骨架、内容类型、菜单、引用、概要等等。
date: 2018-04-23
publishdate: 2018-04-23
lastmod: 2018-04-23
menu:
docs:
- parent: "content-management"
+ parent: content-management
weight: 1
keywords: [source, organization]
categories: [content management]
weight: 01 #rem
-draft: false
aliases: [/content/,/content/organization]
toc: false
isCJKLanguage: true
diff --git a/data/articles.toml b/data/articles.toml
index eac45d20a..37b66928f 100644
--- a/data/articles.toml
+++ b/data/articles.toml
@@ -143,7 +143,7 @@
date = "2016-02-23"
[[article]]
- title = "Hugo: A Modern WebSite Engine That Just Works"
+ title = "Hugo: A Modern Website Engine That Just Works"
url = "https://github.com/shekhargulati/52-technologies-in-2016/blob/master/07-hugo/README.md"
author = "Shekhar Gulati"
date = "2016-02-14"
@@ -491,7 +491,7 @@
date = "2014-08-19"
[[article]]
- title = "Going with hugo"
+ title = "Going with Hugo"
url = "http://www.markuseliasson.se/article/going-with-hugo/"
author = "Markus Eliasson"
date = "2014-08-18"
@@ -509,7 +509,7 @@
date = "2014-08-11"
[[article]]
- title = "Beautiful sites for Open Source projects"
+ title = "Beautiful sites for Open Source Projects"
url = "http://beautifulopen.com/2014/08/09/hugo/"
author = "Beautiful Open"
date = "2014-08-09"
@@ -545,7 +545,7 @@
date = "2014-08-03"
[[article]]
- title = "Hugo Is Friggin' Awesome"
+ title = "Hugo Is Freakin' Awesome"
url = "http://npf.io/2014/08/hugo-is-awesome/"
author = "Nate Finch"
date = "2014-08-01"
diff --git a/data/docs.json b/data/docs.json
index fe4efeb22..8eda8d3b2 100644
--- a/data/docs.json
+++ b/data/docs.json
@@ -245,6 +245,13 @@
]
},
{
+ "Name": "Chapel",
+ "Aliases": [
+ "chapel",
+ "chpl"
+ ]
+ },
+ {
"Name": "Cheetah",
"Aliases": [
"cheetah",
@@ -348,6 +355,13 @@
]
},
{
+ "Name": "dns",
+ "Aliases": [
+ "zone",
+ "bind"
+ ]
+ },
+ {
"Name": "Docker",
"Aliases": [
"docker",
@@ -437,7 +451,8 @@
{
"Name": "Fortran",
"Aliases": [
- "fortran"
+ "fortran",
+ "f90"
]
},
{
@@ -1005,6 +1020,12 @@
]
},
{
+ "Name": "properties",
+ "Aliases": [
+ "java-properties"
+ ]
+ },
+ {
"Name": "Protocol Buffer",
"Aliases": [
"protobuf",
@@ -1650,7 +1671,7 @@
"^postcss$"
],
"osEnv": [
- "(?i)^(PATH|PATHEXT|APPDATA|TMP|TEMP|TERM)$"
+ "(?i)^((HTTPS?|NO)_PROXY|PATH(EXT)?|APPDATA|TE?MP|TERM)$"
]
},
"funcs": {
diff --git a/go.mod b/go.mod
index f80bd4941..ba67e8db6 100644
--- a/go.mod
+++ b/go.mod
@@ -2,4 +2,4 @@ module github.com/gohugoio/hugoDocs
go 1.16
-require github.com/gohugoio/gohugoioTheme v0.0.0-20220912070954-88dcaf003b4d // indirect
+require github.com/gohugoio/gohugoioTheme v0.0.0-20221116211530-5ae8dcdd68d6 // indirect
diff --git a/go.sum b/go.sum
index 91fe56887..c6f539c80 100644
--- a/go.sum
+++ b/go.sum
@@ -37,3 +37,7 @@ github.com/gohugoio/gohugoioTheme v0.0.0-20220905093719-cb8b64046950 h1:Ovlh3nuy
github.com/gohugoio/gohugoioTheme v0.0.0-20220905093719-cb8b64046950/go.mod h1:kpw3SS48xZvLQGEXKu8u5XHgXkPvL8DX3oGa07+z8Bs=
github.com/gohugoio/gohugoioTheme v0.0.0-20220912070954-88dcaf003b4d h1:UYJL6RmEepprvlgHvDnFCWtPOvjmqzFCQ90cRDRBO7U=
github.com/gohugoio/gohugoioTheme v0.0.0-20220912070954-88dcaf003b4d/go.mod h1:kpw3SS48xZvLQGEXKu8u5XHgXkPvL8DX3oGa07+z8Bs=
+github.com/gohugoio/gohugoioTheme v0.0.0-20220914071648-0ef1c51685bf h1:A8Ksnvp8reNt2Ap0mUK7gFkJkCjt9R60yopGsezcOBA=
+github.com/gohugoio/gohugoioTheme v0.0.0-20220914071648-0ef1c51685bf/go.mod h1:kpw3SS48xZvLQGEXKu8u5XHgXkPvL8DX3oGa07+z8Bs=
+github.com/gohugoio/gohugoioTheme v0.0.0-20221116211530-5ae8dcdd68d6 h1:eG53kL1LkQuKmrDdzbvvx6d60qM07zp2Wjo/tYxkDOY=
+github.com/gohugoio/gohugoioTheme v0.0.0-20221116211530-5ae8dcdd68d6/go.mod h1:kpw3SS48xZvLQGEXKu8u5XHgXkPvL8DX3oGa07+z8Bs=
diff --git a/layouts/partials/boxes-section-summaries.html b/layouts/partials/boxes-section-summaries.html
new file mode 100644
index 000000000..7568539e4
--- /dev/null
+++ b/layouts/partials/boxes-section-summaries.html
@@ -0,0 +1,39 @@
+<div class="relative {{ .classes }} weight-{{ .context.Weight }}">
+
+ <div class="bg-white mb2 pa3 pa4-l gray">
+ {{ if eq .context.Section "news" }}
+ <date class="f6 db" datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">
+ {{ .context.Date.Format "January 2, 2006" }}
+ </date>
+ {{ end }}
+
+ <h1 class="near-black f3">
+ <a href="{{ .context.RelPermalink }}" class="link primary-color dim">
+ {{- if eq .context.Section "functions" -}}
+ {{ .context.LinkTitle }}
+ {{- else -}}
+ {{ .context.Title }}
+ {{- end -}}
+ </a>
+ </h1>
+
+ <div class="lh-copy links">
+ {{ if eq .context.Section "commands" }}
+ {{ replaceRE `(?s).*?##\s.*?\n\n(.*?)\n.*` "$1" .context.RawContent }}
+ {{ else }}
+ {{ if .context.Params.description }}
+ {{ .context.Params.description | markdownify }}
+ {{ else }}
+ {{ .context.Summary }}
+ {{ end }}
+ {{ end }}
+
+ <a href="{{ .context.RelPermalink }}" class="f6 mt2 db link primary-color dim">
+ Read More &raquo;
+ </a>
+
+ </div>
+
+
+ </div>
+</div>
diff --git a/netlify.toml b/netlify.toml
index 6b6276364..f3a152a4f 100644
--- a/netlify.toml
+++ b/netlify.toml
@@ -3,7 +3,7 @@ publish = "public"
command = "hugo --gc --minify"
[context.production.environment]
-HUGO_VERSION = "0.102.3"
+HUGO_VERSION = "0.105.0"
HUGO_ENV = "production"
HUGO_ENABLEGITINFO = "true"
@@ -11,20 +11,20 @@ HUGO_ENABLEGITINFO = "true"
command = "hugo --gc --minify --enableGitInfo"
[context.split1.environment]
-HUGO_VERSION = "0.102.3"
+HUGO_VERSION = "0.105.0"
HUGO_ENV = "production"
[context.deploy-preview]
command = "hugo --gc --minify --buildFuture -b $DEPLOY_PRIME_URL"
[context.deploy-preview.environment]
-HUGO_VERSION = "0.102.3"
+HUGO_VERSION = "0.105.0"
[context.branch-deploy]
command = "hugo --gc --minify -b $DEPLOY_PRIME_URL"
[context.branch-deploy.environment]
-HUGO_VERSION = "0.102.3"
+HUGO_VERSION = "0.105.0"
[context.next.environment]
HUGO_ENABLEGITINFO = "true"
diff --git a/resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_1024x512_fill_catmullrom_top_2.png b/resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_1024x512_fill_catmullrom_top_2.png
new file mode 100644
index 000000000..545cfb2d2
--- /dev/null
+++ b/resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_1024x512_fill_catmullrom_top_2.png
Binary files differ
diff --git a/resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_640x0_resize_catmullrom_2.png b/resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_640x0_resize_catmullrom_2.png
new file mode 100644
index 000000000..417ac696c
--- /dev/null
+++ b/resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_640x0_resize_catmullrom_2.png
Binary files differ
diff --git a/resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_8298a1fa052279512823ecd663d6f9c8.png b/resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_8298a1fa052279512823ecd663d6f9c8.png
new file mode 100644
index 000000000..e09003583
--- /dev/null
+++ b/resources/_gen/images/showcase/alora-labs/featured_hu15e97d42270c9e985a93353bc5eb2110_83801_8298a1fa052279512823ecd663d6f9c8.png
Binary files differ
diff --git a/static/images/hosting-and-deployment/hosting-on-azure/basic-app-details.png b/static/images/hosting-and-deployment/hosting-on-azure/basic-app-details.png
new file mode 100644
index 000000000..6cd39424e
--- /dev/null
+++ b/static/images/hosting-and-deployment/hosting-on-azure/basic-app-details.png
Binary files differ
diff --git a/static/images/hosting-and-deployment/hosting-on-azure/create-in-portal.png b/static/images/hosting-and-deployment/hosting-on-azure/create-in-portal.png
new file mode 100644
index 000000000..07dffbae6
--- /dev/null
+++ b/static/images/hosting-and-deployment/hosting-on-azure/create-in-portal.png
Binary files differ