Docs: improve documentation of duplicates and UIEventSource

This commit is contained in:
Pieter Vander Vennet 2023-10-24 21:40:34 +02:00
parent a9bfe4f37b
commit b7a88ced70
2 changed files with 12 additions and 4 deletions

View file

@ -669,7 +669,7 @@ export class UIEventSource<T> extends Store<T> implements Writable<T> {
)
}
static asBoolean(stringUIEventSource: UIEventSource<string>) {
static asBoolean(stringUIEventSource: UIEventSource<string>): UIEventSource<boolean> {
return stringUIEventSource.sync(
(str) => str === "true",
[],