Skip to content
Source
Docs
Explore
Skills
MCP servers
For agents
Search or jump to…
Sign in
Sign up
fuko
/
trytanstackdb.com
Pull requests
fuko
trytanstackdb.com
Public
Synced with GitHub
Fork
0
0
0
0
1
2
3
4
5
6
7
8
9
Code
Architecture
Issues
Pull requests
Community
Assets
CI
Agents
Settings
Show reload button when IndexedDB deletion is blocked
#39
Send to my agent
Merged
fuko
merged 1 commit into
main
from
refs/pull/39/head
·
merged by
fuko
11 months ago
View on GitHub
Conversation
3
Commits
1
Files changed
1
Impact
Showing
1 changed file
with
15 additions
and
1 deletion
.
x
0 of 1 viewed, 1 left
Files
Hide whitespace
Unified
Split
15 additions and 1 deletion
+15
-1
src/routes/__root.tsx
Modified
Diff
Before/After
Viewed
src/routes/__root.tsx
View file
Expand up
Show all 70 lines
@@ -71,6 +71,8 @@
71
71
function
RemoveDB
() {
72
72
const
[errorMessage, setErrorMessage] = useState<
string
|
null
>(
null
);
73
73
74
+
const
[showReloadButton, setShowReloadButton] =
useState
(
false
);
75
+
74
76
const
removeDB =
useCallback
(
async
() => {
75
77
if
(
typeof
window !==
"undefined"
&&
"indexedDB"
in
window) {
76
78
try
{
Show all 9 lines
@@ -86,8 +88,9 @@
86
88
setErrorMessage
(errorMessage);
87
89
};
88
90
request.
onblocked
= () => {
91
+
setShowReloadButton
(
true
);
89
92
const
errorMessage =
90
-
"Database deletion blocked - close other tabs using this site"
;
93
+
"Database deletion blocked - close other tabs using this site. If this site is not open in other tabs, try refreshing the page."
;
91
94
setErrorMessage
(errorMessage);
92
95
console.
warn
(errorMessage);
93
96
};
Show all 16 lines
@@ -110,6 +113,17 @@
110
113
<
RotateCwIcon
/>
Reset
the db
111
114
</
Button
>
Home
Search
Explore
Menu