-
Notifications
You must be signed in to change notification settings - Fork 39
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
iOS: table view selection doesn't really work #92
Comments
Good one This seems hard to fix because if you want to make |
Yeah, I'd really like to avoid making |
On Mac we save and restore the selected indexes: https://github.com/joshaber/Few.swift/blob/221ff4ccf6c339bb7d815398614556b07a80073d/Few-Mac/TableView.swift#L53-56 Could we do that on iOS too? |
@Adlai-Holler you can do something like this to preserve the selection:
To me it seems ok that elements do not have state. You can make component that wraps TableView element and adds state in this way. Otherwise leaving state management to native implementation of UITableView seems to me like leaky abstraction. |
Hi there!!! |
@joshaber We call
reloadData()
every time we diff a TableView, and that kills our selection. I'll work on this one – just putting it here as a reminder.Current thinking is we need to make
Element
equatable, and not callreloadData()
unless our row data has actually changed. Thoughts?The text was updated successfully, but these errors were encountered: