chore: Adds initial code.

This commit is contained in:
Tera << 8 2024-04-17 00:51:53 +00:00
parent a4ea6406e6
commit 939eb0b9d7
8 changed files with 1282 additions and 17 deletions

View file

@ -1 +1,22 @@
console.log("Hello, world!");
import process from "node:process";
import { PrismaClient } from '@prisma/client';
import Fastify from "fastify";
const prisma = new PrismaClient();
const fastify = Fastify({
logger: true
});
fastify.get('/', async function handler (request, reply) {
return { hello: 'world' };
})
// Run the server!
try {
await fastify.listen({ port: 3000 });
} catch (err) {
fastify.log.error(err);
process.exit(1);
}