Configure and customize navigation menus in Bengal.
Overview
Bengal supports multiple menu types that can be configured in frontmatter or configuration files.
Frontmatter Configuration
Add pages to menus directly in frontmatter:
1 2 3 4 5 6 7 8 9 | |
Configuration File Menus
Define menus inbengal.tomlfor non-content pages:
1 2 3 4 5 6 7 8 9 | |
Menu Properties
| Property | Type | Description |
|---|---|---|
name |
string | Display text (defaults to page title) |
url |
string | Link destination |
weight |
integer | Sort order (lower = first) |
pre |
string | HTML before name (icons, etc.) |
post |
string | HTML after name |
parent |
string | Parent menu item for nesting |
identifier |
string | Unique ID for parent references |
Nested Menus
Create hierarchical menus withparentandidentifier:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | |
Accessing Menus in Templates
1 2 3 4 5 6 7 8 9 10 | |