import type { FastifyReply, FastifyRequest } from "fastify";
import type { IRouteInfo } from "../../interfaces/routes";

const routeInfo: IRouteInfo = {
    enabled: true,
    path: "/",
    method: "GET"
};

async function route(request : FastifyRequest, reply : FastifyReply) : Promise<string> {
    const siteData = {
        title: "Home",
    };

    return reply.viewAsync("index", {
        ...siteData,
    });
}

export default { routeInfo, route }