Primarily driven by the upcoming custom output format feature (#2828).
Rationale:
{{ ... }}).Do we want to drive the potential lookup based upon the Output Format? So, if we have a "JSON" Output Format, we would lookup:
This would exclude index.json.html. Lookup would essentially be:
{{ .Name }}.{{ .Format }}{{ .Name }}.{{ .Format }}.tmplOriginal discussion: https://discuss.gohugo.io/t/custom-output-formats-feedback-wanted/5886/2
Hello,
"Can't assume that we're dealing with HTML-type formats any longer."
But we still assume a text output?
If not, then maybe it is the way to handle images?
Can I kindly ask for contributor's vision of image processing?
Notes:
The only native image processing support: #3158
But we still assume a text output?
yes.
I would like to second predictability in IDE aspect.
For example in PhpStorm there is no way to assign *.html to the Go Template file type (provided by a plugin) without _removing_ it from HTML file type globally across all projects. :\
In Intellij Idea products *.gohtml is used for Go Templates
Maybe extension should be customizable, so any extensions instead of html can be used.
Btw, my current workaround is to have *.gohtml for every layout *.html:
โโโ layouts
โ โโโ 404.gohtml
โย ย โโโ 404.html
โย ย โโโ home.gohtml
โย ย โโโ home.html
and include *.gohtml from *.html:
home.html
{{ template "home.gohtml" . }}
Another workaround Iโm currently using:
single.html.html for HTML output format)*.html.html as pattern for Go Template file types in the Jetbrains IDE.Simple *.html files are still being assigned to the HTML file type that way.
While writing a prettier plugin to fix go template support I stumbled upon this. It would be really nice for formatters, if GoHugo would support .tmpl.
+1, this would simplify usage with IntelliJ IDEA-based editors.
Most helpful comment
In Intellij Idea products
*.gohtmlis used for Go TemplatesMaybe extension should be customizable, so any extensions instead of
htmlcan be used.