Skip to content

Commit 96bea44

Browse files
committed
fix: enable CORS for HEAD request in image preview component
1 parent b2d29ce commit 96bea44

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

custom/preview.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ onMounted(async () => {
7878
try {
7979
const response = await fetch(url.value, {
8080
method: 'HEAD',
81+
mode: 'cors',
8182
});
8283
const ct = response.headers.get('Content-Type');
8384
if (ct) {

0 commit comments

Comments
 (0)