mirror of
https://github.com/danbulant/Mangades
synced 2026-07-06 03:20:42 +00:00
fix requests not working
This commit is contained in:
parent
ec8230c1d2
commit
d3c3283b4d
2 changed files with 3 additions and 3 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
<script>
|
<script>
|
||||||
import request from "../util/request";
|
import request, { imageproxy } from "../util/request";
|
||||||
|
|
||||||
export var mangaId;
|
export var mangaId;
|
||||||
|
|
||||||
|
|
@ -14,7 +14,7 @@
|
||||||
Loading art
|
Loading art
|
||||||
{:then list}
|
{:then list}
|
||||||
{#each list.data.sort((a, b) => a.attributes.volume - b.attributes.volume) as item}
|
{#each list.data.sort((a, b) => a.attributes.volume - b.attributes.volume) as item}
|
||||||
<img on:click={() => selectedImage = `https://uploads.mangadex.org/covers/${mangaId}/${item.attributes.fileName}.512.jpg`} width=512 height=805 src="https://uploads.mangadex.org/covers/{mangaId}/{item.attributes.fileName}.512.jpg" alt="" draggable={false}>
|
<img on:click={() => selectedImage = `{imageproxy}https://uploads.mangadex.org/covers/${mangaId}/${item.attributes.fileName}.512.jpg`} width=512 height=805 src="https://uploads.mangadex.org/covers/{mangaId}/{item.attributes.fileName}.512.jpg" alt="" draggable={false}>
|
||||||
{/each}
|
{/each}
|
||||||
{/await}
|
{/await}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
export const proxy = "https://cors-anywhere.danbulant.cloud/";
|
export const proxy = "https://cors-anywhere.danbulant.cloud/";
|
||||||
export const imageproxy = "https://cors-anywhere.danbulant.workers.dev/";
|
export const imageproxy = "https://cors-anywhere.danbulant.workers.dev/?";
|
||||||
export const base = proxy + "https://api.mangadex.org/";
|
export const base = proxy + "https://api.mangadex.org/";
|
||||||
|
|
||||||
function request(endpoint, query, type = "GET", body) {
|
function request(endpoint, query, type = "GET", body) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue