Skip to content

Commit

Permalink
fix: react query offline behavior (#636)
Browse files Browse the repository at this point in the history
* fix: react query offline behavior

* docs(changeset): Fixed react query offline behavior
  • Loading branch information
avivm authored Jun 27, 2023
1 parent 30a0227 commit 01ed858
Showing 2 changed files with 9 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/metal-foxes-arrive.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@krud-dev/ostara-main": patch
---

Fixed react query offline behavior
4 changes: 4 additions & 0 deletions app/src/renderer/apis/useCreateQueryClient.ts
Original file line number Diff line number Diff line change
@@ -6,7 +6,11 @@ const useCreateQueryClient = (): QueryClient => {
() =>
new QueryClient({
defaultOptions: {
mutations: {
networkMode: 'always',
},
queries: {
networkMode: 'always',
refetchOnMount: true,
refetchOnWindowFocus: false,
refetchInterval: false,

0 comments on commit 01ed858

Please sign in to comment.