@@ -54,6 +54,17 @@ const ssr = useRouteQuery<string, boolean>('ssr', 'false', {
54
54
const prod = useRouteQuery <string , boolean >(' prod' , ' false' , {
55
55
transform: stringToBooleanTransformer ,
56
56
})
57
+
58
+ const currentHref = shallowRef (location .href )
59
+ const route = useRoute ()
60
+
61
+ watch (() => route .fullPath , () => {
62
+ currentHref .value = location .href
63
+ })
64
+
65
+ const issueLink = computed (() => {
66
+ return ` https://github.com/vueuse/vueuse/issues/new?template=bug_report.yml&reproduction=${encodeURIComponent (currentHref .value )} `
67
+ })
57
68
</script >
58
69
59
70
<template >
@@ -86,6 +97,16 @@ const prod = useRouteQuery<string, boolean>('prod', 'false', {
86
97
aria-label =" GitHub"
87
98
/>
88
99
</UTooltip >
100
+ <UTooltip text =" Report an issue on GitHub" >
101
+ <UButton
102
+ color =" neutral"
103
+ variant =" ghost"
104
+ :to =" issueLink"
105
+ target =" _blank"
106
+ icon =" i-pajamas-issue-new"
107
+ aria-label =" Issue via GitHub"
108
+ />
109
+ </UTooltip >
89
110
</div >
90
111
<div class =" lg:hidden" >
91
112
<USlideover title =" Settings" >
@@ -101,6 +122,16 @@ const prod = useRouteQuery<string, boolean>('prod', 'false', {
101
122
<USelectMenu v-model =" vueVersion" :items =" vueVersionsSorted" class =" w-32" icon =" i-logos-vue" :loading =" loadingVersions" />
102
123
<UButton icon =" i-lucide-refresh-ccw" size =" md" color =" primary" variant =" soft" @click =" fetchVersions" />
103
124
</div >
125
+ <UButton
126
+ color =" neutral"
127
+ variant =" ghost"
128
+ :to =" issueLink"
129
+ target =" _blank"
130
+ icon =" i-pajamas-issue-new"
131
+ aria-label =" Issue via GitHub"
132
+ >
133
+ Report an issue on GitHub
134
+ </UButton >
104
135
</section >
105
136
</template >
106
137
</USlideover >
0 commit comments