Skip to content

Commit

Permalink
fix(ios): proper cleanup of reused listview cell content (NativeScrip…
Browse files Browse the repository at this point in the history
  • Loading branch information
CatchABus authored Aug 8, 2024
1 parent 499fe8d commit dca7718
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/core/ui/list-view/index.ios.ts
Original file line number Diff line number Diff line change
Expand Up @@ -460,8 +460,9 @@ export class ListView extends ListViewBase {
if (!cell.view) {
cell.owner = new WeakRef(view);
} else if (cell.view !== view) {
// Remove view from super view now as nativeViewProtected will be null afterwards
(<UIView>cell.view.nativeViewProtected)?.removeFromSuperview();
this._removeContainer(cell);
(<UIView>cell.view?.nativeViewProtected)?.removeFromSuperview();
cell.owner = new WeakRef(view);
}

Expand Down

0 comments on commit dca7718

Please sign in to comment.