open source WOTB_GLOSSARY

This commit is contained in:
tresabhi committed 2026-11-08 18:38:46 -06:00
1 parent e50cc6cf5d
commit ad0c8b3431
4 files changed
+13 -16

No files matched your search

+4 -4
View File
@@ -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;
}