mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-11-10 11:16:10 +01:00
open source WOTB_GLOSSARY
This commit is contained in:
4 files changed
+13
-16
No files matched your search
@@ -1,11 +1,11 @@
|
||||
import { assertSecret } from "../blitzkit";
|
||||
import type { BlitzGlossary } from "../types";
|
||||
|
||||
export const WOTB_GLOSSARY_DOMAIN = "https://na.wotblitz.com";
|
||||
export const WOTB_GLOSSARY_PATH = "api/glossary/stuff";
|
||||
|
||||
export async function fetchGlossary(locale: string) {
|
||||
const response = await fetch(
|
||||
`${assertSecret(
|
||||
import.meta.env.WOTB_GLOSSARY_DOMAIN,
|
||||
)}/${locale}${assertSecret(import.meta.env.WOTB_GLOSSARY_PATH)}`,
|
||||
`${WOTB_GLOSSARY_DOMAIN}/${locale}/${WOTB_GLOSSARY_PATH}`,
|
||||
);
|
||||
return (await response.json()) as BlitzGlossary;
|
||||
}
|
||||
Reference in new issue
Block a user