Anchor links to another page before custom code loads

This is a twist on the common question of anchor links to another page.
To bypass some of webflow’s limitations, I have a page (called Evenements) that load elements (Chef Menus) from another, page through custom code.
These Chef Menus are within sections for which I need anchor links accessible through a dropdown menu (in the main Nav Bar).
When I am on the Evenements page, the anchor links take me to the right section. So far so good.
The issue appears when I am on other pages, and access the anchor links through the dropdown menu. The link takes me where the section would be if the Chef Menus hadn’t been loaded (because, obviously, it’s not loaded yet when I press the anchor link). Therefore, it’s way off.
Does anyone have a solution for this? Perhaps somehow slowing down the anchor link so the page loads before it determines where to go?
Hope someone takes up that challenging problem!

Here is my read-only : Webflow - Roland Michon
To experience the site properly, you’ll need to go on the published version, because, custom code : Évènements

Hi @fredericG what about this?

Did you try prerender?

That’s a great cue, but unfortunately, it doesn’t change anything :confused: