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]: Docs for shouldRevalidate make it sound like it is only for opting out #11470

Open
steinybot opened this issue Apr 17, 2024 · 0 comments
Labels

Comments

@steinybot
Copy link

steinybot commented Apr 17, 2024

Describe what's incorrect/missing in the documentation

The docs for shouldRevalidate only mention the case for opting out of data revalidation. From my investigation and testing it also supports the opposite case of triggering revalidation when the default would have been false. It should say that you can also opt-in when the default is false.

This is relevant to react-router-relay where we need to force revalidation when the relay environment changes and the queries have been disposed of. I had a question from a maintainer of react-router-relay asking whether this was a suitable usage of shouldRevalidate. I'm pretty sure that it is but it would be much more reassuring if the docs mention it and we can rely on it staying that way.

@steinybot steinybot added the docs label Apr 17, 2024
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

1 participant