I have created a custom theme from scratch, everything works perfectly except one thing, in my home page
Vendor/Theme/Magento_Theme/layout/default.xml
I can't place my 'main' container after my 'header' container Here is the code:
<page layout="3columns" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<container name="header.container.panel.nav" htmlTag="header" before="main.content">
//Some stuff
</container>
<container name="main.content" htmlTag="main" after="header.container.panel.nav">
//Some stuff
</container>
</body>
</page>
What I have tried:
- Using dash instead of container name in the before and after instruction
- Moving the definition of the main.content container before header
- adding
<move element="main.content" destination="body" after="header.container.panel.nav"/>
Even if I'm not sure that the instruction destination="body" work as intended.