Thanks Xavier for the tip! This is exactly what i was looking for! I created a little extension so that it's really easy to include an expandable list in a template using an include. You can just define the root node and the style you want to use and then include the template to show the expandable list.