From e62f7afdc22e7ad28166922c17feb047e2020915 Mon Sep 17 00:00:00 2001 From: Joseph Abrahamson Date: Sun, 3 May 2020 12:13:15 -0400 Subject: [PATCH] docs: clarify store contract type signature (#4539) --- site/content/docs/01-component-format.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/content/docs/01-component-format.md b/site/content/docs/01-component-format.md index 07a59c69f8..fa851ccc41 100644 --- a/site/content/docs/01-component-format.md +++ b/site/content/docs/01-component-format.md @@ -175,7 +175,7 @@ Local variables (that do not represent store values) must *not* have a `$` prefi ##### Store contract ```js -store = { subscribe: (subscription: (value: any) => void) => () => void, set?: (value: any) => void } +store = { subscribe: (subscription: (value: any) => void) => (() => void), set?: (value: any) => void } ``` You can create your own stores without relying on [`svelte/store`](docs#svelte_store), by implementing the *store contract*: