summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSerghei Iakovlev <egrep@protonmail.ch>2022-05-29 23:36:18 +0200
committerSerghei Iakovlev <egrep@protonmail.ch>2022-05-29 23:36:18 +0200
commit6a7082eab5f4bfa1912ce0ec4d7e790ecf3bbcc6 (patch)
treedc826aa41a1573906c1377971a3aabf9f2059ba1
parent6d98543832e4a339f2b386eafb8f091d877b0d3f (diff)
downloadgohugo-theme-ed-6a7082eab5f4bfa1912ce0ec4d7e790ecf3bbcc6.tar.gz
Provide ability to include custom scripts in the them
-rw-r--r--CHANGELOG.md8
-rw-r--r--layouts/partials/head.html4
2 files changed, 9 insertions, 3 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 64610ac..1eeda7d 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
+## [Unreleased](https://github.com/sergeyklay/gohugo-theme-ed/compare/v0.2.0...HEAD)
+
+### Added
+
+- Provide ability to include custom scripts in the theme.
+
## [v0.2.0](https://github.com/sergeyklay/gohugo-theme-ed/compare/v0.1.0...v0.2.0)
### Added
@@ -13,7 +19,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Add Russian translation
- Provide an ability to use hreflang attribute in `link` shortcode
- Add `{{< mini-toc >}}` shortcode
-- Provide an ability to use `keywords` meta tag
+- Provide ability to use `keywords` meta tag
- Provide ability to render feeds menu
- Add pagination support
diff --git a/layouts/partials/head.html b/layouts/partials/head.html
index 14cd475..39e3255 100644
--- a/layouts/partials/head.html
+++ b/layouts/partials/head.html
@@ -14,7 +14,7 @@
{{ hugo.Generator }}
{{- partial "styles.html" . }}
- {{- partial "custom-scripts.html" . }}
+ {{ block "custom-scripts" . }}{{ partial "custom-scripts.html" . }}{{ end }}
{{- /* Favicons */}}
<link rel="icon" href="{{ site.Params.assets.favicon | default "favicon.ico" | relURL }}" sizes="any"><!-- 32×32 -->
@@ -28,7 +28,7 @@
<link rel="alternate" hreflang="{{ .Lang }}" href="{{ .Permalink }}">
{{ end -}}
- {{- partial "custom-head.html" . -}}
+ {{ block "custom-head" . }}{{ partial "custom-head.html" . }}{{ end }}
{{- /* Misc */}}
{{ template "partials/templates/opengraph.html" . }}