Skip to content

Commit

Permalink
fix: Always force reload to fetch latest data
Browse files Browse the repository at this point in the history
  • Loading branch information
surajshetty3416 committed Jan 3, 2025
1 parent ee1612c commit f838976
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions frontend/src/store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -379,6 +379,11 @@ const useStore = defineStore("store", {
const targetWindow = window.open(`/${route}`, "builder-preview");
if (targetWindow?.location.pathname === `/${route}`) {
targetWindow?.location.reload();
} else {
setTimeout(() => {
// wait for the page to load
targetWindow?.location.reload();
}, 50);
}
},
savePage() {
Expand Down

0 comments on commit f838976

Please sign in to comment.