September 2020
Beginner to intermediate
456 pages
11h 4m
English
This chapter covers
This chapter focuses on using stores to share data between components, regardless of their relationship in the component hierarchy. Stores provide an alternative to using props or context. They hold application state outside any component. Each store holds a single JavaScript value, but the value can be an array or an object, which of course can hold many values.
Svelte supports several kinds of stores.
Writable stores allow components to change their data.
Readable stores do not allow components to change their data because the store itself ...
Read now
Unlock full access