fix(store): add missing `derived` type definition (#6172)

pull/6184/head
Fielding Johnston 3 years ago committed by GitHub
parent 5c309a5a78
commit 3b4d53e611
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -133,6 +133,20 @@ export function derived<S extends Stores, T>(
initial_value?: T
): Readable<T>;
/**
* Derived value store by synchronizing one or more readable stores and
* applying an aggregation function over its input values.
*
* @param stores - input stores
* @param fn - function callback that aggregates the values
* @param initial_value - initial value
*/
export function derived<S extends Stores, T>(
stores: S,
fn: (values: StoresValues<S>) => T,
initial_value?: T
): Readable<T>;
/**
* Derived value store by synchronizing one or more readable stores and
* applying an aggregation function over its input values.

Loading…
Cancel
Save