I have a Hugo website that was originally built with version 0.08x.x and has recently been upgraded to 0.110.x.
The issue with the site is that it uses shortcodes and raw HTML in the front matter, which complicates readability and automatic translation of the content.
I am using a YAML-based translator, which works well for other websites. To use it on the aforementioned site, I need to convert the front matter to YAML and move the raw HTML and shortcode definitions to a layout. The layout should be dynamic so that it can be reused for multiple pages at the same level.
So far, I’ve tried various approaches without success. I consulted ChatGPT, which suggested moving the shortcodes to a layout and passing the parameters from the front matter to the layout. However, this approach failed, as I believe shortcodes are not supported in layouts. I encountered the following error:
_default\products.html:4:1": parse failed unexpected "<" in command
What are your suggestions for converting my front matter to YAML, creating a dynamic layout, and reusing it across multiple pages? Are there any tools that can assist with this?