From 7fdf0b8df78ee89b70efe708777bf4e3e3528a82 Mon Sep 17 00:00:00 2001 From: Moein Date: Wed, 30 Sep 2020 12:58:13 +0330 Subject: [PATCH] fix: Set return type of get_store_value to store value type --- src/runtime/internal/utils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/runtime/internal/utils.ts b/src/runtime/internal/utils.ts index b31832c35f..3b8815cb1d 100644 --- a/src/runtime/internal/utils.ts +++ b/src/runtime/internal/utils.ts @@ -62,7 +62,7 @@ export function subscribe(store, ...callbacks) { return unsub.unsubscribe ? () => unsub.unsubscribe() : unsub; } -export function get_store_value>(store: S): T { +export function get_store_value(store: Readable): T { let value; subscribe(store, _ => value = _)(); return value;