Skip to content

Commit

Permalink
🐛 (composable/event-loader) cors除外指定の追加
Browse files Browse the repository at this point in the history
  • Loading branch information
Shion1305 committed Oct 25, 2023
1 parent f731c86 commit 30e69cc
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion composables/events-loader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@ export async function useDataLoader() {
events_data = await (async function (): Promise<EventData[]> {
const downloaded_data: EventData[] = [];
try {
const zip_data = await fetch(zipUrl).then((res) => res.blob());
// disable CORS
const zip_data = await fetch(zipUrl, {
mode: "no-cors",
}).then((res) => res.arrayBuffer());
const zip = await JSZip.loadAsync(zip_data);
const fileNames = Object.keys(zip.files);

Expand Down

0 comments on commit 30e69cc

Please sign in to comment.