From 1853847d2e80bef0b062b318c3d8208c8432c7bf Mon Sep 17 00:00:00 2001 From: henzyd Date: Fri, 23 Aug 2024 03:51:17 +0100 Subject: [PATCH] chore: created empty next api --- src/app/api/hello/route.ts | 7 +++++++ src/app/page.tsx | 5 +++++ 2 files changed, 12 insertions(+) create mode 100644 src/app/api/hello/route.ts diff --git a/src/app/api/hello/route.ts b/src/app/api/hello/route.ts new file mode 100644 index 0000000..f9763eb --- /dev/null +++ b/src/app/api/hello/route.ts @@ -0,0 +1,7 @@ +import { NextResponse } from "next/server"; + +export async function GET() { + return NextResponse.json({ + data: "Hello World", + }); +} diff --git a/src/app/page.tsx b/src/app/page.tsx index 3f5e9a1..8e26ba7 100644 --- a/src/app/page.tsx +++ b/src/app/page.tsx @@ -1,5 +1,6 @@ "use client"; +import Link from "next/link"; import { notifyError, notifyInfo, notifySuccess } from "~/utils/toast"; export default function Home() { @@ -16,6 +17,10 @@ export default function Home() { + +
+ Go to API +
); }