initial commit

This commit is contained in:
René Schober
2026-03-13 06:23:06 +01:00
commit 4e34270786
314 changed files with 37280 additions and 0 deletions

26
apps/server/src/index.ts Normal file
View File

@@ -0,0 +1,26 @@
import { auth } from "@haushaltsApp/auth";
import { env } from "@haushaltsApp/env/server";
import { Hono } from "hono";
import { cors } from "hono/cors";
import { logger } from "hono/logger";
const app = new Hono();
app.use(logger());
app.use(
"/*",
cors({
origin: env.CORS_ORIGIN,
allowMethods: ["GET", "POST", "OPTIONS"],
allowHeaders: ["Content-Type", "Authorization"],
credentials: true,
}),
);
app.on(["POST", "GET"], "/api/auth/*", (c) => auth.handler(c.req.raw));
app.get("/", (c) => {
return c.text("OK");
});
export default app;