add prettier config

This commit is contained in:
Lee
2023-10-17 23:41:42 +01:00
parent f6f56aa09c
commit 27f3c4e030
75 changed files with 549 additions and 543 deletions

View File

@ -97,12 +97,12 @@ export async function fetchUrl(url, options = {}, cors = true) {
export async function fetchJson(
url,
{ cacheTtl = null, maxAge = null, ...restOptions } = {},
{ cacheTtl = null, maxAge = null, ...restOptions } = {}
) {
const options = getOptionsWithCacheKey(
url,
{ cacheTtl, maxAge, ...restOptions },
"json",
"json"
);
const {
@ -129,7 +129,7 @@ export async function fetchJson(
body,
},
fetchCacheKey,
fetchCacheTtl,
fetchCacheTtl
);
})
.catch((err) => {
@ -141,12 +141,12 @@ export async function fetchJson(
export async function fetchHtml(
url,
{ cacheTtl = null, maxAge = null, ...restOptions } = {},
{ cacheTtl = null, maxAge = null, ...restOptions } = {}
) {
const options = getOptionsWithCacheKey(
url,
{ cacheTtl, maxAge, ...restOptions },
"json",
"json"
);
const {
@ -172,7 +172,7 @@ export async function fetchHtml(
body: new DOMParser().parseFromString(body, "text/html"),
},
fetchCacheKey,
fetchCacheTtl,
fetchCacheTtl
);
});
}