I'm using web sockets to update a list of comments. I'm nesting ul and li tags to produce the threaded style (explained here).
The problem is that when a new message comes in, I don't want to re-render the entire list of messages. Is there way to manipulate the DOM (preferably with jQuery), to insert the new message into the right "nest" of the list?
Or is there a better way to structure my HTML? (Perhaps a way that uses the parent and child ids as html attributes)