you mean like youd rather do it the other way around?

This commit is contained in:
Rowan 2025-10-08 06:46:15 -04:00
parent afa0170041
commit 4210f500c4

View file

@ -46,8 +46,13 @@ class ServerSideRenderer(Renderer):
for element in puppygirl.elements:
if hasattr(element, "name"):
for tag in tree.find_all(element.name):
new_tag = element.render(SingleNode(tag).clone(), templates)
tags = tree.find_all(element.name)
tags.reverse()
for tag in tags:
new_tag = element.render(
SingleNode(tag).clone(),
templates
)
if isinstance(new_tag, Iterable):
tag.extend(new_tag)