I want to display a menu structure that will look like
<ul>
<li>
MenuItemName1
<ul>
<li>Child Item</li>
</ul>
</li>
<li>
MenuItemName2
</li>
</ul>
I have a menuitem class that contains menu, name, url and children menu items. I would like to create a partial view that displays each item as an unordered list, as mentioned above, and I would call it recursively to go through the whole tree.
It is a bad idea? Will it be very slow?
source
share