krausest / js-framework-benchmark

A comparison of the performance of a few popular javascript frameworks
https://krausest.github.io/js-framework-benchmark/
Apache License 2.0
6.68k stars 828 forks source link

Improve Non-Keyed Vanilla Implementations #936

Open ryansolid opened 3 years ago

ryansolid commented 3 years ago

I tend to treat that table like it doesn't exist so I haven't looked at it for months (years?), but noticed Remove Rows in the vanilla implementation seems to be slower than a handful of implementations. We should look at improving it.

If anyone in the community familiar with Non-Keyed wants to contribute I think this is a worthwhile effort. Vanilla should be the fastest and without it being so it compromises the value of the particular tests.

lxsmnsyc commented 3 years ago

I'm interested on improving this, although I was curious as to why the Remove Row seems to be slower than the keyed version

lxsmnsyc commented 3 years ago

I had written my own take on the vanillajs implementation image

Tho it seems to me that both implementations are just patching elements and not actually replacing them. Is that a valid approach?

lxsmnsyc commented 3 years ago

image

Anyways, I didn't saw the note above so I just reworked it a bit.

krausest commented 2 years ago

@LXSMNSYC Would you like to submit a PR for that?

lxsmnsyc commented 2 years ago

@LXSMNSYC Would you like to submit a PR for that?

It's actually my own take. I didn't try to update both vanillajs and vanillajs-1 due to their select implementation. In a nutshell, my implementation assumes that data and view are both in sync.

krausest commented 2 years ago

That would be fine. You could just submit a new vanillajs implementation and I'd remove the others when I checked that it's the fastest.