1
0
Fork 0
mirror of https://github.com/mealie-recipes/mealie.git synced 2025-07-21 22:29:39 +02:00
mealie/frontend/server/routes/openapi.json.ts

10 lines
246 B
TypeScript
Raw Permalink Normal View History

import { joinURL } from "ufo";
export default defineEventHandler(async (event) => {
const apiUrl = useRuntimeConfig().apiUrl; // 'http://localhost:9000'
const target = joinURL(apiUrl, event.path);
return proxyRequest(event, target);
});