253 karma · joined April 13, 2020
around 2 yrs ago, i messed up benchmarks in the past with million v1. i'm sorry about putting out false information. once the reddit post came out i stopped working/advertising million entirely. i then spent 3 months redesigning the entire library. i tried my best to make it as fast as possible and accurate. benchmarks are real now, see here: https://krausest.github.io/js-framework-benchmark/current.ht...
I'm open to different ways to market Million if there is a specific tagline you have in mind
My intention wasn't to dismiss your point at all btw. My intention was if there wasn't any 3rd party benchmark for a library (like js-framework-benchmark), you shouldn't take claims at face value unless you've done due diligence. It's great to hear that you're keeping yourself accountable, hopefully Million will also sometime soon :)
Other than that, thank you so much for all the awesome feedback, it's really appreciated :)
This isn't to say virtual DOM isn't fast Experimental libraries that use virtual DOM's like blockdom and ivi (see https://krausest.github.io/js-framework-benchmark/2022/table...) are very, very fast.
At the end of the day, the way libraries render UI is a set of tradeoffs. No one method is objectively better. While lit works great for a lot of web developers, so do virtual DOM based libraries
Totally agree on native DOM diffing, I'll check out Apple's proposal :)
This is how the Virtual Node tree is constructed. One case could be a React.createElement call that creates a virtual div node. You can visualize it by going to this page (Scroll down to the REPL section): https://millionjs.org/docs/api/basics/m
> a sort of buffered visual rendering on the (presumably more powerful) server that was used to determine exactly which elements needed to be rendered for the given view, then passing the associated DOM tree nodes to the browser for actual rendering
This is called hydration: https://en.wikipedia.org/wiki/Hydration_(web_development)
Nothing too flashy, just simple and straight to the point
This is in contrast to the DOM, or the native rendering method for JavaScript, which requires developers to specify imperative steps to "construct" the user interface.
Virtual DOM is useful because it makes it much easier to create user interfaces, but comes at the cost of rendering performance. Million aims to make close the gap between DOM (native) and Virtual DOM performance through compilation, or optimizing certain "predefined routes" to native code, allowing for optimal rendering speed.
You can read more about virtual DOM here: https://millionjs.org/blog/virtual-dom
Basically anything that guides you in building a virtual DOM is a good article