top | item 22444534

(no title)

alexrage | 6 years ago

> Component state should only contain volatile data that is not important to save, the opposite of LocalStorage.

Where do you store data that you retrieve from a server for rendering? Storing it in the state is perfectly fine. In this example, data is retrieved from local storage and stored in the state.

discuss

order

the_gipsy|6 years ago

Fair point, but server state is tied ti my account, LS is not. You can tie LS to the account, but IMO that would be out of scope for an "everything component" approach, like the article.