2024-09-14 18:07:49 +02:00
|
|
|
import "dotenv/config";
|
2024-09-05 22:29:12 +02:00
|
|
|
import { env } from "node:process";
|
2024-09-30 22:05:14 +02:00
|
|
|
import { Limits } from "~/lib/api/meta";
|
2024-09-05 22:29:12 +02:00
|
|
|
|
|
|
|
export const API_BASE = env.API_BASE || "https://pronouns.localhost/api";
|
2024-09-10 20:33:22 +02:00
|
|
|
export const LANGUAGE = env.LANGUAGE || "en";
|
2024-09-30 22:05:14 +02:00
|
|
|
|
|
|
|
const apiLimits: Limits = await fetch(`${API_BASE}/v2/meta`)
|
|
|
|
.then((resp) => resp.json())
|
|
|
|
.then((m) => m.limits);
|
|
|
|
export const limits: Limits = Object.freeze(apiLimits);
|