On this page https://gohugo.io/getting-started/configuration-markup#highlight on the syntax highlighting section it mentions
guessSyntax as a markup configuration option.
I couldn’t find any information about what this does, but I am guessing that if this is set to
true then it will try to guess the default syntax inside any codeblock, in-case you don’t specify it manually (like adding
css to specify which syntax highlighting to use in a code-fence:
``` js console.log('test');
When I set it to
true, it does try to insert some
css classes for highlighting, but its setting it to `class=“language-fallback”.
It works when I specify which syntax to use manually in each code block. Is it necessary to always specify this manually in each code block or is it possible to make it automatic? Thanks