There is no information on how you can add custom metadata to your
taxonomy terms. What you need to do is add front matter data in the file
/content/<TAXONOMY>/<TERM>/_index.md
Then you will be able to access the taxonomy term as a page in a
taxonomy terms template.
That is why I added instructions in /content-management/taxonomies on
how to add custom metadata. And in /templates/taxonomy-templates/ I
added an example on how you can display that metadata in the taxonomy
terms template.
I think that would be enough to guide the user in how to add custom
metadata to their taxonomy terms.
35abbc86 Add example with taxonomy for title template func
85e28c10 Remove comment from variable in front matter example
eee8543b Remove comment from variable in front matter example
13a8e0b7 Add missing closing and opening comment tags
83531772 Replace http://example.{com,org}/ with https://example.{com,org}/
6727d820 Update gh repo for issues in config
3a58818e Add note to install Testify
19f13e61 Fix YAML examples in taxonomies.md
dc4b90db Replace old RSS template with new embedded version (#116)
00f39bd7 camelCase output format options
902a14a1 Add missing word to pretty URLs explanation
git-subtree-dir: docs
git-subtree-split: 35abbc869199b852922c024a29e2370272a7c1c8
As pointed out by the linter, some exported functions and types are
missing doc comments.
The linter warnings have been reduced from 194 to 116.
Not all missing comments have been added in this commit though.
As per the referenced issue, if the task list in Markdown has
nothing before it, it will be rendered wrongly:
```
---
title: "My First Post"
date: 2017-07-29T20:21:57+02:00
draft: true
---
* [ ] TaskList
```
is rendered as:
```
<ul> class="task-list"
<li><input type="checkbox" disabled class="task-list-item"> TaskList</li>
</ul>
```
The problem lies in the `List` function of `HugoHTMLRenderer`, it had
a hardocded index of `4` for the first `>` of the list, it is used to
insert the class into the text before the closing bracket, but that
hardcoded index is only right when there is a newline before the
opening bracket, which is the case when there is anything in the
document before the task list, but if there is nothing, then there is
no newline, and the correct index of the first `>` will be `3`.
To fix that we're changing the hardcoded index to be dynamic by using
`bytes.Index` to find it properly. We're also adding a test case to
make sure this is tested against.
Fixes#3710
* docs: Add note to install Testify
The Hugo Contributor Guide (Development) instructs users to run "go test ./..." and ensure it passes before moving on. However Hugo requires the Testify package for testing, and running the go test command without Testify results in 'cannot find package' errors and failing tests. It's hard to understand what to do next for users not familiar with Go dependencies. This commit adds a note to the contributor guide instructing users to get Testify if they don't already have it installed. Running the 'go get' command added here results in passing tests in the next step of the contributor guide.
* Fix typo https:// in go get command
This works for the `title` func and the other places where Hugo makes title case.
* AP style (new default)
* Chicago style
* Go style (what we have today)
Fixes#989
This works for the `title` func and the other places where Hugo makes title case.
* AP style (new default)
* Chicago style
* Go style (what we have today)
Fixes#989