# Reuse Discourse Hamburger Functionality

**URL:** <https://meta.discourse.org/t/reuse-discourse-hamburger-functionality/85578>\
**Category:** Product Support\
**Created:** [April 17, 2018, 9:42pm UTC](https://meta.discourse.org/t/reuse-discourse-hamburger-functionality/85578 "2018-04-17T21:42:12Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![sarahann](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sarahann/32/96703_2.png) [@sarahann](https://meta.discourse.org/u/sarahann)\
**Post date:** [April 19, 2018, 7:51pm UTC](https://meta.discourse.org/t/reuse-discourse-hamburger-functionality/85578/6 "2018-04-19T19:51:34Z")

</div>

Yes! This is very close!

My only concern was the connect part:

> [@awesomerobot](#):
>
> api.attachWidgetAction(‘header’, ‘togglePizza’, function() {  
> this.state.pizzaVisible = !this.state.pizzaVisible;  
> });

What if I wanted to add the pizza menu to a custom HTML element (defined in common/head\_tag.html)?

---

_[View the full topic](https://meta.discourse.org/t/reuse-discourse-hamburger-functionality/85578)._
