i'm trying to find and alter the last comment node in a page (which will change periodically).
something like
<!-- first comment -->
<!-- second comment -->
<!-- third comment -->
<something></something>
the element following the last comment will always be "something", maybe there's a way to just grab the node before "something"? having a hard time unpacking how dealing with nodes works
edit: i've found answers about finding all the comment nodes but can't figure out how to select only the last one. an additional hazard is that this is a weird project where i need to specifically use custom elements without ids or classes