# Not getting menu from Navigation editor

**URL:** <https://community.hubspot.com/t/not-getting-menu-from-navigation-editor/38749>\
**Category:** CMS Development\
**Created:** [June 10, 2021, 8:18pm UTC](https://community.hubspot.com/t/not-getting-menu-from-navigation-editor/38749 "2021-06-10T20:18:04Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![abe\_pop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/abe_pop/32/69256_2.png) [@abe\_pop](https://community.hubspot.com/u/abe_pop)\
**Post date:** [June 10, 2021, 8:18pm UTC](https://community.hubspot.com/t/not-getting-menu-from-navigation-editor/38749/1 "2021-06-10T20:18:04Z")

</div>

Good afternoon all,

I am currently building a custom theme for a website, and am in the process of writing a draft. I have built a menu in the Navigation Editor and am trying to make it appear on the webpage. However, for some reason, it is not appearing in either the theme menu or the content creator interface when I drag and drop to create a new menu. The theme so far is an adaptation of the boilerplate code available from HubSpot, and it uses the menu() function in the boilerplate module “menu-section.module.”

In order to diagnose the issue, I printed module.primary\_menu\_field and menu(module.primary\_menu\_field)|pprint. The first one prints out the menu ID correctly. However, the second one (with the menu() function) prints the following:

(PageTreeNode: PageTreeNode{label=null, url=null, children=, activeBranch=false, activeNode=false, level=0, pageTitle=null, pageId=null, slug=null, linkTarget=null})

After that, the menu itself is meant to be returned in the boilerplate code by:

renderNavigation(menu(module.primary\_menu\_field))

But the menu does not appear, I presume because the menu function is returning what appears to be an empty PageTreeNode.

Is it possible that somehow HubSpot is not finding the menu from the Navigation Editor? Is there any possible resolutions? Any help would be appreciated. Thank you!

Best,  
Abe

---

<div class="post-metadata">

**Author:** ![dennisedson](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/dennisedson/32/28044_2.png) [@dennisedson](https://community.hubspot.com/u/dennisedson)\
**Post date:** [June 11, 2021, 2:40pm UTC](https://community.hubspot.com/t/not-getting-menu-from-navigation-editor/38749/2 "2021-06-11T14:40:17Z")

</div>

[@abe\_pop](https://community.hubspot.com/t5/user/viewprofilepage/user-id/194821) ,

The pprint makes it appear like there are no items to print for the menu. Do you have items (not draft) in the menu?

---

<div class="post-metadata">

**Author:** ![abe\_pop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/abe_pop/32/69256_2.png) [@abe\_pop](https://community.hubspot.com/u/abe_pop)\
**Post date:** [June 11, 2021, 2:50pm UTC](https://community.hubspot.com/t/not-getting-menu-from-navigation-editor/38749/3 "2021-06-11T14:50:34Z")

</div>

Thank you for your response. I think I do. See the image below:

 ![Screen Shot 2021-06-11 at 10.49.37 AM.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/b/c/bcc6cc41978a98c38d3fbe78b3a86ef461ae6d6e.png)

---

<div class="post-metadata">

**Author:** ![dennisedson](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/dennisedson/32/28044_2.png) [@dennisedson](https://community.hubspot.com/u/dennisedson)\
**Post date:** [June 11, 2021, 2:51pm UTC](https://community.hubspot.com/t/not-getting-menu-from-navigation-editor/38749/4 "2021-06-11T14:51:36Z")

</div>

[@abe\_pop](https://community.hubspot.com/t5/user/viewprofilepage/user-id/194821) .

Just for fun, can you add another item that does not have a page associated with it?

Or an page that is not in draft. I believe the menu will not print links to pages in draft mode

---

<div class="post-metadata">

**Author:** ![abe\_pop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/abe_pop/32/69256_2.png) [@abe\_pop](https://community.hubspot.com/u/abe_pop)\
**Post date:** [June 11, 2021, 3:00pm UTC](https://community.hubspot.com/t/not-getting-menu-from-navigation-editor/38749/5 "2021-06-11T15:00:45Z")

</div>

Interesting. For the first time, I am seeing something more than nothing. The relevant code (omitting most of the module, which is from the boilerplate) is below:

```lia-code-sample
<nav aria-label="Main menu" class="navigation-primary">
 {{ module.primary_menu_field }}
 {{ menu(module.primary_menu_field)|pprint }}
 {{ renderNavigation(menu(module.primary_menu_field)) }}
</nav>

```

The menu editor and the relevant part of my header partial are shown below:

 ![Screen Shot 2021-06-11 at 10.55.08 AM.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/e/b/eb92c4a60bddbad2e1696fb3f4581784dac3814c.png)

 ![Screen Shot 2021-06-11 at 10.57.12 AM.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/5/a/5ad2810acf2d8060a87e6066f5ef9fb528f0ccc5.png)

---

<div class="post-metadata">

**Author:** ![dennisedson](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/dennisedson/32/28044_2.png) [@dennisedson](https://community.hubspot.com/u/dennisedson)\
**Post date:** [June 11, 2021, 3:02pm UTC](https://community.hubspot.com/t/not-getting-menu-from-navigation-editor/38749/6 "2021-06-11T15:02:42Z")

</div>

I believe the issue is that the pages you have in that menu are in a draft state. If you subsituted with published pages, they would appear.

---

<div class="post-metadata">

**Author:** ![abe\_pop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/abe_pop/32/69256_2.png) [@abe\_pop](https://community.hubspot.com/u/abe_pop)\
**Post date:** [June 11, 2021, 3:08pm UTC](https://community.hubspot.com/t/not-getting-menu-from-navigation-editor/38749/7 "2021-06-11T15:08:52Z")

</div>

Thank you so much for the clarification. I haven’t published any pages yet (they are just called test[N] where N is a number I increment), so that explains why they are not appearing. As I move forward, I will just not make them link to pages until those pages are published, so I can build out the menu accordingly.
