Skip to content

Latest commit

 

History

History
109 lines (66 loc) · 2.01 KB

File metadata and controls

109 lines (66 loc) · 2.01 KB
id TanStackStoreSelector
title TanStackStoreSelector

Class: TanStackStoreSelector<TSource, TSelected>

Defined in: tan-stack-store-selector.ts:22

Type Parameters

TSource

TSource

TSelected

TSelected = NoInfer<TSource>

Implements

  • ReactiveController

Constructors

Constructor

new TanStackStoreSelector<TSource, TSelected>(
   host, 
   getStore, 
   selector, 
options?): TanStackStoreSelector<TSource, TSelected>;

Defined in: tan-stack-store-selector.ts:35

Parameters

host

ReactiveControllerHost

getStore

() => SelectionSource<TSource> | undefined

selector

(snapshot) => TSelected

options?

UseSelectorOptions<TSelected>

Returns

TanStackStoreSelector<TSource, TSelected>

Methods

hostDisconnected()

hostDisconnected(): void;

Defined in: tan-stack-store-selector.ts:72

Called when the host is disconnected from the component tree. For custom element hosts, this corresponds to the disconnectedCallback() lifecycle, which is called the host or an ancestor component is disconnected from the document.

Returns

void

Implementation of

ReactiveController.hostDisconnected

hostUpdate()

hostUpdate(): void;

Defined in: tan-stack-store-selector.ts:48

Called during the client-side host update, just before the host calls its own update.

Code in update() can depend on the DOM as it is not called in server-side rendering.

Returns

void

Implementation of

ReactiveController.hostUpdate