Multilingual menus : deletes the frontmatter data relative to the menu

Hi ! I’m using as a CMS. “auto-detects” menus and will give you the possibility to edit them via the UI.

I don’t use this feature but I have some “menu data” in my content pages frontmatter which is deleted by Forestry each time I try to edit the page in question.

Example of removed code in /references/ :

    parent: references
    weight: 1

As a result, each time I try to edit those pages via the CMS, they disappear from my menu.

It’s quite problematic for me, because I want the user to be able to create new pages (which will be added to the menu) and I don’t know another way of making this work via Hugo, other than using the Menus.

I’m aware this is maybe more of a Forestry issue, but since there seems to be no way of saying “don’t auto-detect” my menus, I’m looking for a Hugo-side way.

Thanks for your help.

Hi there,

What you could try is configuring your menus via config.toml instead of via the frontmatter: Menu Templates | Hugo

However, if you need your menus defined in your frontmatter, you will have to ask the Forestry people how to resolve that.

Hello and thank you for the reply !

I am already using the config file to configure my menus, but I also need the data in the frontmatter for my “child” pages, and for Hugo to be able to add those pages to the nav when the user creates a new page.