Liqiud basics
Modules
API
Mailer
Menus
Overview
There are different types of menus in liquid. They will generate different types of menus.
| Name | Description |
| {{ 'root' | menu }} | Only display the root pages (first level pages) |
| {{ 'full' | menu }} | Will show all parents and children |
| {{ 'sub' | menu }} | Get a sub menu based on the root parent |
| {{ 'sub-4568' | menu }} | Get a sub menu based on an existing page ID |
| {{ 'map' | menu }} | Will show all parents and children even if "visible in menu" is not checked |
All different menus is showing pages that has the "published" and "visible in menu" settings checked in the page settings. Except the map menu tag which only needs to have "published" checked.
'root' | menu
This is a basic menu. This is commonly used for the navbar when you want a simple menu.
'full' | menu
This menu will give you root pages and all of the sub pages. This menu can be good to use in a responsive menu since it will give you sub pages that you can later style to toggle on mobile devices.
'sub' | menu
This menu will show sub pages of the page that you are currently visiting. This is commonly used on default pages for a side menu. This menu is dynamic and will change content based on which page you are on.
'sub-4568' | menu
If you want to display sub pages of a specific page you can use this menu tag by adding the page ID.
You can use this on occasions where you always want to display a specific sub menu.
You can find the id belonging to a specific page by, in the page settings, hovering over the page title. The numbers that you see after /admin/pages/XXXX is the id. For example /admin/pages/4568
'map' | menu
This is pretty much the same as 'full'. The only difference is that map will show pages even though they don't have the "visible in menu" checked
Updated: 2019-11-19