errorf and warnf are nice. But somehow they clogg the logs if they get too OCD. I want to add a way to my shortcodes/components to debug fromt “paranoid” (every step noted) to “just casual” (just errors for instance). Similarily to the -v to -vvv in many linux command line programs. Is that something I should propose as a feature or is it overkill for Hugo or even a technical menace?
Right now I am doing it via a config parameter that defines the level of output and my errorf and warnf calls are in partials that check for the level of noise before deciding if they can throw.
my current process is to have a single partial per directory. The standard partial is named c.html. If I need to debug that one then I duplicate it to d.html and add the errorf and warnf where needed. Then call that one from a specific point I need to debug. Eg:
It would be nice to be able to have custom file extensions. I would like to use partials/compounds/figure/c.gtml instead of the standard .html. That way I can map .gtml to go templates formatter in the editor I’m using.
The editor I am currently using doesn’t allow mapping file extensions to pretty-print formatters at the project or folder level.