How would I go about looping through the entire items in a menu but only get the items from the last nested list? Say I have the following menu:
- Animals
- cat
- dog
- parrot
- Food
- Drinks
- water
- Pepsi
- booze
- Fruit
- apple
- pear
- carrot
- Drinks
The items in bold is what I mean - the end of the line so to speak in each root item.