Channel Menu
The ChannelMenu
action allows you to create a navigation menu in the sidebar of Shopify admin on desktop. On Shopify mobile, the menu is rendered in a dropdown, like NavigationMenu.
Create an app and import the ChannelMenu
module from @shopify/app-bridge/actions
. The examples in this guide refer to the @shopify/app-bridge
sample app:
Create any number of AppLink
instances and then pass them into ChannelMenu
.
Set an active nav item
Anchor link to section titled "Set an active nav item"To update the active state for the menu, pass a link to the active
option using the set
method.
Reset active nav item
Anchor link to section titled "Reset active nav item"To clear the active link pass undefined
as the active
option using the set
method: