LightNet v4 is here! Learn how to upgrade your site
Set a main menu
LightNet supports adding a main menu to the header bar, displayed as a hamburger icon in the top-right corner. The menu can link to internal or external pages.
Here’s an example configuration:
export default defineConfig({ integrations: [ lightnet({ // ... mainMenu: [ { href: "/", label: { en: "Home", }, }, { href: "/media", label: { en: "Media", }, }, { href: "/about", label: { en: "About", }, }, { href: "https://lightnet.community", label: { en: "LightNet", }, }, ], }), ],})This example menu configuration links to:
- the home page on
/ - the search page on
/media - the about page on
/about - an external website on https://lightnet.community
Notice that the links do not include a locale. LightNet adds the locale automatically.
Menu item properties
Section titled “Menu item properties”href: Defines the link destination. It can be an internal link, such as/media, or an external link, such ashttps://wikipedia.org. External links open in a new browser tab.label: The text displayed on the menu item. Provide a locale map keyed by your configured site languages, for example{ en: "About", de: "Über uns" }.