diff --git a/src/components/map/default-layers.js b/src/components/map/default-layers.js index a3284081..76f3d5f1 100644 --- a/src/components/map/default-layers.js +++ b/src/components/map/default-layers.js @@ -134,7 +134,12 @@ export const DefaultLayers = () => { } return(data); }; - useQuery( {queryKey: ['apsviz-default-data', data_url], queryFn: getDefaultLayers, enable: !!data_url}); + useQuery({ + queryKey: ['apsviz-default-data', data_url], + queryFn: getDefaultLayers, + enable: !!data_url, + refetchOnWindowFocus: false, + }); // maybe should convert this one to use useQuery - not sure how to do that yet useEffect(() => { diff --git a/src/components/trays/model-selection/synopticTab.js b/src/components/trays/model-selection/synopticTab.js index b7c3239c..fea8455d 100644 --- a/src/components/trays/model-selection/synopticTab.js +++ b/src/components/trays/model-selection/synopticTab.js @@ -93,7 +93,9 @@ export const SynopticTabForm = () => { // return something return true; - } + }, + + refetchOnWindowFocus: false }); /** diff --git a/src/components/trays/model-selection/tropicalTab.js b/src/components/trays/model-selection/tropicalTab.js index 1775a24a..c5124127 100644 --- a/src/components/trays/model-selection/tropicalTab.js +++ b/src/components/trays/model-selection/tropicalTab.js @@ -90,7 +90,10 @@ export const TropicalTabForm = () => { // return something return true; - } + }, + + refetchOnWindowFocus: false + }); /**