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

@@ -1,4 +1,9 @@
import { assertSecret, type BlitzGlossary } from "@blitzkit/core";
import {
WOTB_GLOSSARY_DOMAIN,
WOTB_GLOSSARY_PATH,
type BlitzGlossary,
} from "@blitzkit/core";
import locales from "@blitzkit/i18n/locales.json";
import type { APIContext, GetStaticPathsItem } from "astro";
import sharp from "sharp";
import { mixStaticPaths } from "../../../../core/blitzkit/mixStaticPaths";
@@ -30,7 +35,9 @@ export const getStaticPaths = mixStaticPaths(_getStaticPaths, async () => {
});
}
const glossary = await fetch(assertSecret(import.meta.env.WOTB_GLOSSARY))
const glossary = await fetch(
`${WOTB_GLOSSARY_DOMAIN}/${locales.default}/${WOTB_GLOSSARY_PATH}`,
)
.then((response) => response.json() as Promise<BlitzGlossary>)
.then((glossary) =>
Object.values(glossary)
-5
View File
@@ -26,10 +26,5 @@ PUBLIC_PROMOTE_OPENTEST=false
# Legacy variable; this will be removed soon
PUBLIC_STATIC_ASSET_BASE=https://assets.blitzkit.app
# Proprietary Wargaming fields; you shouldn't need these for 99% of the tasks
WOTB_GLOSSARY=
WOTB_GLOSSARY_DOMAIN=
WOTB_GLOSSARY_PATH=
# Generate your own application id: https://developers.wargaming.net
PUBLIC_WARGAMING_APPLICATION_ID=