feat(frontend): grab limits from API, add created time + member count to settings
This commit is contained in:
parent
4002893323
commit
562ecc46bd
7 changed files with 174 additions and 114 deletions
|
|
@ -1,5 +1,11 @@
|
|||
import "dotenv/config";
|
||||
import { env } from "node:process";
|
||||
import { Limits } from "~/lib/api/meta";
|
||||
|
||||
export const API_BASE = env.API_BASE || "https://pronouns.localhost/api";
|
||||
export const LANGUAGE = env.LANGUAGE || "en";
|
||||
|
||||
const apiLimits: Limits = await fetch(`${API_BASE}/v2/meta`)
|
||||
.then((resp) => resp.json())
|
||||
.then((m) => m.limits);
|
||||
export const limits: Limits = Object.freeze(apiLimits);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue