Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Fix #220: in value Attrs, check equality during View propagation #223

Merged
merged 1 commit into from
Jul 31, 2021

Conversation

Tarmil
Copy link
Member

@Tarmil Tarmil commented Jul 27, 2021

cc @cata

This should fix the cursor jump issue by checking for equality early in the View propagation.

I was also wondering whether we should remove the check before setting the Var here; but I think it's still useful to avoid doing multiple propagations because both input and keypress are triggered.

@Tarmil Tarmil requested review from Jand42 and granicz July 27, 2021 13:35
@granicz
Copy link
Member

granicz commented Jul 29, 2021

Yes, this is good, thanks! I wonder what performance benefit it also brings. Do you have any idea?

@granicz
Copy link
Member

granicz commented Jul 30, 2021

FYI, @steiner2001 revived @evancz's TodoMVC benchmark and plugged in the 4.7/5.0-preview WebSharper versions and the latest React one. As expected, WebSharper.UI still performs ~5-10% better than React (which is amazing since we haven't touched the fundamentals in UI for years). We can gauge this PR soon against the WS4.7 numbers - https://steiner2001.github.io/react_vs_websharper_UI_Performance/

@granicz granicz merged commit 8015431 into master Jul 31, 2021
@granicz
Copy link
Member

granicz commented Aug 2, 2021

FYI - latest benchmark shows roughtly the same performance as before.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

In input controls, cursor sporadically jumps to the end of text while typing
3 participants