hugo-profile
hugo-profile copied to clipboard
Frontmatter images conflicts with Hugo definition
Describe the bug
Markdown pages fail to build with images:
set in the front matter.
To Reproduce Steps to reproduce the behavior:
- Add front matter to markdown with
images:
- src: /test.jpg
- Fails to build
Expected behavior Expect to build
Screenshots N/A
Desktop (please complete the following information):
- OS: [e.g. iOS] Any
- Browser [e.g. chrome, safari] Any
- Version [e.g. 22] Any
- Theme: v4.0.5
Additional context
https://github.com/gurusabarish/hugo-profile/blob/4687d533368288e9f71d358dca30099f29535531/layouts/_default/gallery.html#L22
This uses a .src on the images array, whereas the Hugo definition for front matter images only includes images as []string
which makes it conflicting. If Hugo does not error, the theme errors and vice versa.
Fix would be to change it to {{ . }}
.
On second look, this was modified in behavior with https://github.com/gurusabarish/hugo-profile/commit/0c564693b306ae4fa629ef68f72a2cefa840f0fa
But this is not released as a tag. Will keep this issue open.
@adyanth new tag released.
https://github.com/gurusabarish/hugo-profile/releases/tag/v4.051