11 lines
272 B
TypeScript
Raw Normal View History

2023-08-01 17:50:00 +02:00
import { Handlers } from "$fresh/server.ts";
import { getAllRecipes } from "@lib/resource/recipes.ts";
import { json } from "@lib/helpers.ts";
export const handler: Handlers = {
async GET() {
const recipes = await getAllRecipes();
return json(recipes);
},
2023-07-26 13:47:01 +02:00
};