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

Dynamic view update in epoxy through data binding approch #1360

Open
ranjeetscience opened this issue Jul 18, 2023 · 0 comments
Open

Dynamic view update in epoxy through data binding approch #1360

ranjeetscience opened this issue Jul 18, 2023 · 0 comments

Comments

@ranjeetscience
Copy link

Hi,
We are using epoxy library in our app for our SDUI usecase with data binding approach. The problem is , our UI is too much stateful, means bases on some user action we have to update the ui a lot.

Example, we used camera scanner to scan qr code, once user scan the qr we have to update our already inflated epoxy view with scanned value at some particular position.
Other example is that , based on some server condition we have to make view visible or gone which is also dynamic.
Similar issue happen for edit text and edit text change listener if we have to update view based on what user is typing

The problem is that simply changing that data class value and updating the adapter does not do anything and in most of the cases it crashes(Epoxy attribute fields on a model cannot be changed once .....)

I went to lot of open/closed issue , docs and blog and most of the places it mentioned we have to immutable data class only and if required we should use copy method. But for us it view state is getting updated at too many places and doing this make code really unreadable. Can you help with this?

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

No branches or pull requests

1 participant