Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Docs Rewrite] New Page: Data Fetching and Caching #3613

Open
7 tasks
phryneas opened this issue Nov 11, 2019 · 4 comments
Open
7 tasks

[Docs Rewrite] New Page: Data Fetching and Caching #3613

phryneas opened this issue Nov 11, 2019 · 4 comments
Labels
Milestone

Comments

@phryneas
Copy link
Member

phryneas commented Nov 11, 2019

The Docs Rewrite should contain a "Data Fetching and Caching" Page that discusses peculiarities of data-fetching itself as well as implementation advice, both with redux as well as some advice on doing the same without redux.

Topics to be covered:

  • cancellation on new request
  • cache invalidation, as a combination of tracking which cache is currently being used by components and timeouts
  • normalization of API results
  • things to be considered in combination with concurrent mode
  • functions of higher order to generate slices with low boilerplate
  • an overview over middlewares that lend themselves to the topic
  • an overview over non-redux libraries that might be used to achieve similar results
@timdorr timdorr added the docs label Nov 11, 2019
@timdorr timdorr added this to the Docs Rewrite milestone Nov 11, 2019
@markerikson markerikson changed the title [Docs Rewrite] Meta-Issue: Data Fetching and Caching [Docs Rewrite] New Page: Data Fetching and Caching Nov 11, 2019
@markerikson
Copy link
Contributor

We probably ought to have some advice on working with loading states with and without Suspense in here, too.

@phryneas
Copy link
Member Author

Definitely.
I'm gonna experiment with suspense soon, as I'm also a little involved with https://github.com/async-library/future and https://github.com/async-library/react-async.

One question: if it would prove to be useful with suspense - how would you feel about suggesting to store a Promise or thenable in a Redux state? I know, it's not serializable per se, but in combination with a toJSON property and a `reviver' function for JSON.parse, we maybe could establish a good pattern on how to work with that.

@markerikson
Copy link
Contributor

Still a no, because the serialization check middleware in RSK will throw errors.

@phryneas
Copy link
Member Author

Okay, let's see how far we get without it :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants