Show HN: I made a better DOM morphing algorithm
5 comments
·November 7, 2025sillysaurusx
I’m curious, what got you interested in solving this particular problem? I.e. what was your specific use case?
Most websites work fine with plain html. If you need something fancier, the world seems to have settled on using React.
I get that this is to let you render html on the backend and then stream it to the site so that JS can update the dom. But why? Genuine question; I’m not saying there’s no good reason.
nzoschke
I’m doing agentic coding on a bunch of web apps and server side rendering HTML is so much easier than building APIs and React components.
Full page reloads are fine for most CRUD cases. Then layering DOM morphing can be even better UX almost for free
rtcode_io
Can you see if you can support the input-to-output sync of the examples you see on https://rtcode.io ?
Does your library support the new state-preserving moveBefore method?
rtcode_io
Sorry, I was excited to see something newer than diffHTML and asked questions before reading the full article! You do use moveBefore with lots of effort to match elements, which makes Morphlex a very interesting library to try!
I will test your library extensively and update you via GitHub in case of questions/issues!
Thank you for releasing Morphlex!
Uptrenda
Is there a website where we can try this out on?
At least I think it’s better, but also I could also be missing something obvious.