# Hoe toon ik een widget in het hamburger menu?

**URL:** <https://meta.discourse.org/t/how-to-display-a-widget-in-the-hamburger-menu/167022>\
**Category:** Product Support\
**Created:** [12 oktober 2020 om 21:02 UTC](https://meta.discourse.org/t/how-to-display-a-widget-in-the-hamburger-menu/167022 "2020-10-12T21:02:38Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)\
**Post date:** [12 oktober 2020 om 21:02 UTC](https://meta.discourse.org/t/how-to-display-a-widget-in-the-hamburger-menu/167022/1 "2020-10-12T21:02:38Z")

</div>

Hi,

I’d like to display a widget in the hamburger menu. I lookes at [(Deprecated) Display a "Discord Widget" in a dropdown button](https://meta.discourse.org/t/how-to-display-discord-widget-in-a-dropdown-button/73719) to figure it out. but I’m not able to show the button in the hamburger menu.  
Here’s my code:

```js
const showModal = require("discourse/lib/show-modal").default;

api.createWidget("modal-button", {
  tagName: "a.test",

  html() {
    return "Open Modal";
  },

  click() {
    showModal("fareharbor");
  }
});

api.decorateWidget("hamburger-menu:generalLinks", function(helper) {
  return [helper.attach('modal-button')];
});

```

What am I doing wrong?

---

_[View the full topic](https://meta.discourse.org/t/how-to-display-a-widget-in-the-hamburger-menu/167022)._
