docs: clarify writable value is lost when destroyed

Closes #4610
Closes #4407
pull/6461/head
Simon H 3 years ago committed by GitHub
parent 5f584d165a
commit 92fba761a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -294,6 +294,8 @@ const unsubscribe = count.subscribe(value => {
unsubscribe(); // logs 'no more subscribers'
```
Note that the value of a `writable` is lost when it is destroyed, for example when the page is refreshed. However, you can write your own logic to sync the value to for example the `localStorage`.
#### `readable`
```js

Loading…
Cancel
Save