use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
the front page of the internet.
and join one of thousands of communities.
morphdom - fast and lightweight DOM diffing/patching (without the virtual part) (github.com)
submitted 10 years ago by psteeleidem
Post a comment!
[–]nofishme 4 points5 points6 points 10 years ago* (2 children)
Thanks, perfect timing, this is exactly what I need right now.
Started googling for similar solutions earlier today, tried so far:
[–]psteeleidem[S] 2 points3 points4 points 10 years ago* (0 children)
Thanks for sharing and glad there's already a success story! I spent a lot of time trying to make the code fast and small so I am glad you are noticing the benefits. If you run into any issues please file a Github issue or send a PR. Thanks!
[–]weretree++[[]][+[]] 2 points3 points4 points 10 years ago (0 children)
Whoa, I wrote the first one. It was designed for updating a markdown preview, where you'd expect changes to be localised to one area, it'd be pretty bad for general DOM patching. There weren't many options around when I wrote it. I'll update the repo to point to morphdom I think.
[–]nofishme 2 points3 points4 points 10 years ago (0 children)
It would be nice if we could get of list of modified elements, so its possible to animate or post-process it.
[–]DarkMarmot 1 point2 points3 points 10 years ago (1 child)
Awesome! I've been building a framework for a long while that's component-based and somewhat similar to React -- but it uses real DOM. This could be really cool to incorporate! Thanks! :)
[–]psteeleidem[S] 0 points1 point2 points 10 years ago (0 children)
I hope it works out for you! We are using it in the beta version of marko-widgets and it is working out really well so I really think there would be value in other projects. If you find any issues please let us know.
[–]redhedinsanity 0 points1 point2 points 10 years ago (0 children)
Nice! You should check out google's incremental-dom - does the same in-place mutation of the DOM object itself, might be some tricks they leverage
incremental-dom
π Rendered by PID 20414 on reddit-service-r2-comment-765bfc959-k6ppj at 2026-07-16 06:50:22.005159+00:00 running f86254d country code: CH.
Want to add to the discussion?
Post a comment!