After changing the suffix of the HTML output format from html (default) to htm, I unexpectedly found that partial templates still need to end with .html, not .htm, like every other file type.
- hugo.toml:
[mediaTypes]
[mediaTypes.'text/html']
suffixes = ['htm']
[outputFormats]
[outputFormats.htm]
isHTML = true
mediaType = 'text/html'
permalinkable = true
rel = 'canonical'
weight = 10
[outputs]
home = ['htm']
page = ['htm']
section = ['htm']
taxonomy = ['htm']
term = ['htm']
-
Content files, located under
content/
, need to end in .md or .htm. -
Layout files, located under
layouts/
, need to end in .htm. -
Shortcode files, located under
layouts/shortcodes/
, need to end in .htm. -
Markup files, located under
layouts/_default/_markup/
, need to end in .htm. -
Partial files, located under
layouts/partials/
, need to end in .html. Why?