The Navigation Menu API creates a navigation menu for your app. On desktop web browsers, the navigation menu appears as part of the app nav, on the left of the screen. On Shopify mobile, the navigation menu appears in a dropdown from the TitleBar. This is modeled after the [HTML nav element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/nav). Note that nested navigation items are not supported.
import {NavMenu} from '@shopify/app-bridge-react';
export function MyApp() {
return (
<NavMenu>
<a href="/" rel="home">
Home
</a>
<a href="/templates">Templates</a>
<a href="/settings">Settings</a>
</NavMenu>
);
}
The `NavMenu` component is available for use in your app. It configures the sidebar navigation menu in the Shopify admin. The first element is required and used to configure the home route of the app. It is not rendered as a link. It needs to have <code>rel="home"</code> set along with the <code>href</code> set to the root path.