dom VS domdiff

Compare dom vs domdiff and see what are their differences.

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
dom domdiff
30 2
1,535 210
1.8% -
6.5 0.0
7 days ago over 1 year ago
HTML JavaScript
GNU General Public License v3.0 or later ISC License
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

dom

Posts with mentions or reviews of dom. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2024-04-25.
  • A Response to "Have Single-Page Apps Ruined the Web?"
    3 projects | news.ycombinator.com | 25 Apr 2024
    in plain htmx, you can target an area that doesn't disrupt a playing video (e.g. the comments box appending to the comments) or you can use a morphing algorithm that disrupts the DOM less.

    i have my own morphing algorithm (and a corresponding htmx plugin that allows you to use it) called idiomorph:

    https://github.com/bigskysoftware/idiomorph/

    i've also been working with the chrome team to get a feature added they are calling "atomic moves":

    https://github.com/whatwg/dom/issues/1255

    this would allow us to move elements around in the DOM without losing things like play state or focus or whatever

    very excited for this last idea, I think it will be a huge boon for the web in general, not just for htmx

  • HTML Attributes vs. DOM Properties
    2 projects | news.ycombinator.com | 24 Apr 2024
    What I said in my previous comment is observably true. Try making a demo where it isn't.

    > A DOM node is a living mutable thing, but the JavaScript object representing that node is not.

    The JavaScript object is mutable. The first example in the article shows this.

    > That is also why a node list is not an array.

    Modern APIs on the web return platform arrays (eg JavaScript arrays). https://webidl.spec.whatwg.org/#js-sequence - here's where the WebIDL spec specifies how to convert a sequence to a JavaScript array.

    I'm fully aware of NodeList. There's a reason the spec calls them "old-style" https://dom.spec.whatwg.org/#old-style-collections

    > I can understand how this is confusing if you have never operated without a framework, but otherwise itโ€™s really straightforward

    Sighhhhhh. I've been a web developer for over 20 years, and spent a decade on the Chrome team working on web platform features. Most of my career has been on the low-level parts of the platform.

    Could it be possible that people are disagreeing with you, not because they're stupid, but because you're in the wrong? Please try to be open minded. Try creating some demos that test your opinions.

  • Using XPath in 2023
    8 projects | news.ycombinator.com | 16 Jul 2023
    Domenic Denicola (the man who ruined promises) probably will as well.

    https://github.com/whatwg/dom/issues/67

  • Which browser do you recommend, one for personal security-focused use and one for work?
    1 project | /r/browsers | 8 Jun 2023
    I'm pretty sure it is, since I get "TypeError: nodes[i].parentNode.href is undefined" and "TypeError: $mainmenu.parent(...).get(...) is undefined" errors on both Pale Moon and LibreWolf. Which is part of Shadow/DOM, and originated from google (https://hacks.mozilla.org/2015/06/the-state-of-web-components/). Not sure when this particular thing was introduced, since it's a "living standard"/experimental feature (https://dom.spec.whatwg.org/).
  • That people produce HTML with string templates is telling us something
    16 projects | news.ycombinator.com | 26 May 2023
    JSX chose to align names to the DOM spec [0]. Same for htmlFor and friends.

    [0] https://dom.spec.whatwg.org/#ref-for-dom-element-classname%E...

  • Notback BETA - A new PHP frontend framework
    5 projects | /r/PHP | 28 Mar 2023
    You can see why I say this here: https://dom.spec.whatwg.org
  • Understanding the Benefits of "Quirky" Web Languages
    6 projects | dev.to | 28 Mar 2023
    The product logos in this article's cover image include different languages and technologies some of which are still relevant for web development today: HTML, CSS, JavaScript / ES / TypeScript (and the DOM), SVG, PDF, PHP, SQL (mySQL, MariaDB), mongoDB, Node.js (the most successful server-side implementation of JavaScript so far).
  • Declarative Shadow DOM
    5 projects | news.ycombinator.com | 13 Feb 2023
    Thanks for the shout-out! I think I mention this in the talk, but note that YMMV. I designed that benchmark as a kind of "worst-case scenario" where shadow DOM / scoped styles really show a benefit. Depending on your CSS rules, DOM size, and amount of thrashing, the perf benefit could be small to large.

    Also, it's still possible to shoot yourself in the foot, especially if you have a large/complex stylesheet repeated across multiple shadow roots. (Not because of the repetition โ€“ that's optimized in browsers [1] โ€“ but rather because of the number of DOM nodes affected.)

    That said, I still think the perf benefits of shadow DOM have been undersung. And Declarative Shadow DOM makes it way more useful.

    [1]: https://github.com/whatwg/dom/issues/831#issuecomment-585489...

  • HTML DOM ๏ธloves Javascript! ๐Ÿ’• #TLA ๐Ÿ˜˜
    1 project | dev.to | 23 Jan 2023
    We luh-luh-luv you! They gestated and nurtured the spec. They fought over bike sheds! All for us!!
  • AI Found a Bug in My Code
    3 projects | news.ycombinator.com | 16 Nov 2022

domdiff

Posts with mentions or reviews of domdiff. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2022-09-09.
  • Ask HN: What happened to vanilla HTML/CSS/JS development?
    31 projects | news.ycombinator.com | 9 Sep 2022
    > There are lighter-weight shadow dom frameworks out there (than Vue/React/Angular) so why would you want to write one yourself?

    You can even avoid a shadow DOM entirely:

    https://github.com/WebReflection/domdiff

    https://github.com/WebReflection/uhtml

  • Proposal to add efficient DOM diffing to browser
    3 projects | news.ycombinator.com | 3 Apr 2021
    If by faster you mean faster than React I think there is evidence it can be. The author of the issue writes lots of dom utility and rendering libraries and I believe domdiff is more or less what he describes in the post:

    https://github.com/WebReflection/domdiff

    You can find it placed way above React in the usual JS rendering benchmarks:

    https://rawgit.com/krausest/js-framework-benchmark/master/we...

    Now it's not entirely clear whether these benchmarks convey something meaningful except for maybe the point that most frameworks are quite fast. That being said I think it's developer experience that really stands to improve. Thinking of view as a pure function of state was a great innovation, but existing implementations can end up fracturing the view into virtual doms and non-virtual. Then you end up with problems like D3 and React not coexisting.

    I feel like I heard something from the lit-html folks that a long term aspiration was to integrate some learnings from the project into chrome, but I haven't been able to find where again.

    There has been a trend in JS with libraries becoming idiomatic to the language to later have the issues they targeted be addressed natively (a la JQuery).

    In general, I definitely appreciate your point about adding complexity to the platform, but I think when it comes to web technologies that ship has long sailed. I really see it as an opportunity to bring a lot of simplicity, chiefly filling that void that's birthed a billion JS frameworks.

    Thanks for the thoughtful comment.

What are some alternatives?

When comparing dom and domdiff you can also consider the following projects:

hyperHTML - A Fast & Light Virtual DOM Alternative

modern-todomvc-vanillajs - TodoMVC with Modern (ES6+), Vanilla JavaScript

extension-manager - A utility for browsing and installing GNOME Shell Extensions.

notemplate - NoTemplate is not a template library.

brutal - ๐Ÿข An operating system inspired by brutalist design that combines the ideals of UNIX from the 1970s with modern technology and engineering

prehistoric-simulation - Simulator in browser

IntersectionObserver - Intersection Observer

AlgoVis - A web page that visualizes a simple sorting algorithm.

Isotope - :revolving_hearts: Filter & sort magical layouts

web-starter - Starter for Fastify + Web Components/Lit Web App. Includes Reload and web server restart on dev mode.

WHATWG HTML Standard - HTML Standard

go-neon