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

Remove updating cell in non reusable generator #157

Open
ngagarinov opened this issue Jan 15, 2022 · 1 comment
Open

Remove updating cell in non reusable generator #157

ngagarinov opened this issue Jan 15, 2022 · 1 comment
Assignees

Comments

@ngagarinov
Copy link

I thought the basic idea of non reusable generator was not to update the cell configuration in generate(tableView: UITableView, for indexPath: IndexPath) method , but in all NonReusableGenerators we have this. And now we have to update generator model everytime when we change smth in that cell to prevent reset data while scrolling, i don't think it should be like this.
How about removing it ?

@ngagarinov ngagarinov self-assigned this Jan 15, 2022
@NullIsOne
Copy link
Collaborator

NullIsOne commented Jan 28, 2022

We have some misunderstanding of term nonReusable

In last year we added comment to nonReusable generator.

/// Term non-reusable means that we are creating cell manually with constructor type defined in ConstractableItem.
/// In other words this generator will not use `tableView.deqeueReusableCell

This means that nonReusable generator keep reference between one concrete generator and one concrete cell created manually from xib. One to one forever.

But some contributors have opinion that this cell will be configured only once.
This is mistake.

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

No branches or pull requests

2 participants