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

Recursive cached binding #183

Merged
merged 6 commits into from
Nov 10, 2019

Conversation

TysonMN
Copy link
Member

@TysonMN TysonMN commented Nov 8, 2019

Fixes #181

Creates a recursive binding type called CachedBinding<'model, 'msg>. The caching in the OneWayLazy and SubModelSelectedItem cases are removed and now use this cached binding instead.

All the tests pass, and there is an existing test for OneWayLazy that ensures that caching is working.

I left one comment in the code to make sure we have a conversation about it. I will create a comment in this PR on that line next.

@TysonMN TysonMN changed the title #181 recursive cached binding Recursive cached binding Nov 8, 2019
src/Elmish.WPF/ViewModel.fs Outdated Show resolved Hide resolved
src/Elmish.WPF/ViewModel.fs Outdated Show resolved Hide resolved
src/Elmish.WPF/ViewModel.fs Outdated Show resolved Hide resolved
@cmeeren
Copy link
Member

cmeeren commented Nov 8, 2019

Thanks a lot! There's a lot to take in here, but I can't see anything obviously wrong. Could you also just verify that all relevant samples still work? If they do, and all tests still pass, then I think it's good to go (after resolving the other conversations).

@TysonMN
Copy link
Member Author

TysonMN commented Nov 8, 2019

There's a lot to take in here, but I can't see anything obviously wrong.

I tried to separate conceptual changes by commit. Reviewing one commit at a time could help.

Could you also just verify that all relevant samples still work? If they do, and all tests still pass, then I think it's good to go (after resolving the other conversations).

Will do.

@TysonMN
Copy link
Member Author

TysonMN commented Nov 10, 2019

Could you also just verify that all relevant samples still work? If they do, and all tests still pass, then I think it's good to go (after resolving the other conversations).

Will do.

For good measure, I tried all the samples. Everything seemed to work.

@cmeeren
Copy link
Member

cmeeren commented Nov 10, 2019

For good measure, I tried all the samples. Everything seemed to work.

Great, thanks!

@TysonMN TysonMN force-pushed the #181_recursive_cached_binding branch from 38bd805 to 7823e96 Compare November 10, 2019 12:20
@cmeeren
Copy link
Member

cmeeren commented Nov 10, 2019

Looks good to me. Merge when you're ready :)

@TysonMN TysonMN merged commit 7feeb9b into elmish:master Nov 10, 2019
@TysonMN TysonMN deleted the #181_recursive_cached_binding branch November 10, 2019 12:30
@TysonMN TysonMN mentioned this pull request Aug 15, 2020
16 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add recursive cached binding
2 participants