github TanStack/virtual @tanstack/lit-virtual@3.15.0

latest releases: @tanstack/svelte-virtual@3.13.49, @tanstack/angular-virtual@6.1.9
4 hours ago

Minor Changes

  • #1334 91c2931 - Add setOptions to VirtualizerController and WindowVirtualizerController so virtualizer options can be updated after construction.

    Previously the controller only accepted options once, in its constructor, so options derived from reactive Lit properties (count, estimateSize, horizontal, …) could never be re-applied. getVirtualizer().setOptions(...) is not a substitute: it replaces options wholesale and drops the controller's onChange wrapper, which is what asks the host to re-render.

    setOptions takes a partial set of options, merges them over the options the controller already holds (skipping undefined, so an omitted value does not wipe a stored one), re-applies the host requestUpdate wrapper around onChange, and flushes the change:

    willUpdate(changed: PropertyValues<this>) {
      if (changed.has('count')) {
        this.virtualizerController.setOptions({ count: this.count })
      }
    }

Patch Changes

  • Updated dependencies [2343004]:
    • @tanstack/virtual-core@3.19.8

Don't miss a new virtual release

NewReleases is sending notifications on new releases.