Skip to content

Add million@2.0.0 benchmark #1204

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 20 commits into from
Mar 15, 2023
Merged

Add million@2.0.0 benchmark #1204

merged 20 commits into from
Mar 15, 2023

Conversation

aidenybai
Copy link
Contributor

@aidenybai aidenybai commented Mar 10, 2023

Removes unkeyed Million 1.x implementations.

Adds Million 2.x keyed implementation with (#801)

@aidenybai aidenybai marked this pull request as ready for review March 10, 2023 05:35

(() => {
new Block(
stringToDOM(
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this count as too much optimization here?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this code generated by a compiler? (Asking since it's under /src)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, it's not. I can rewrite it such that it uses the canonical API instead, do you think that's more aligned with this bench?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah that would probably be better, I can't imagine people in practice will write code like that.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got it, thanks!

@krausest
Copy link
Owner

No doubt, it's pretty fast, but looking at the code I'm sure we'll have lots of discussions what flags to add (I propose #772).
Bildschirm­foto 2023-03-15 um 22 15 00

@ryansolid
Copy link
Contributor

ryansolid commented Mar 15, 2023

I see.. hmm... @aidenybai you can correct me, but it looks like on select you look up the VDOM nodes and then patch them directly here. I agree this verges on #772. Instead of writing code to describe the selection in the view you do an imperative lookup and mutation.

@aidenybai
Copy link
Contributor Author

Sounds good, I agree with the #772 flag. Is the best way to add a new flag to open up a PR?

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants