perf: virtual list was rendering every single item and then destroying
This commit is contained in:
4 files changed
+77
-49
No files matched your search
@@ -104,7 +104,12 @@
|
||||
bind:posts
|
||||
bind:lastSeen={() => client.lastSeen ?? 0, (v) => (client.lastSeen = v)}
|
||||
bind:params={getParams}
|
||||
virtualList={{ itemHeights: client?.itemHeights ?? [] }}
|
||||
bind:virtualList={
|
||||
() => ({ itemHeights: client.itemHeights ?? [] }),
|
||||
(v) => {
|
||||
if (v) client.itemHeights = v.itemHeights
|
||||
}
|
||||
}
|
||||
/>
|
||||
<svelte:element
|
||||
this={settings.infiniteScroll && !settings.posts.noVirtualize
|
||||
|
||||
Reference in new issue
Block a user