🎉 Initial Commit

This commit is contained in:
2025-01-01 20:10:22 +08:00
commit 8d94eef3c3
15 changed files with 244 additions and 0 deletions

22
src/pages/_app.tsx Normal file
View File

@@ -0,0 +1,22 @@
import "@/styles/globals.css";
import type { AppProps } from "next/app";
import { Roboto } from "next/font/google";
const fontRoboto = Roboto({
subsets: ["latin"],
weight: ["400", "500", "700"],
display: "swap",
});
export default function App({ Component, pageProps }: AppProps) {
return (
<>
<style jsx global>{`
html {
font-family: ${fontRoboto.style.fontFamily};
}
`}</style>
<Component {...pageProps} />
</>
);
}

13
src/pages/_document.tsx Normal file
View File

@@ -0,0 +1,13 @@
import { Html, Head, Main, NextScript } from "next/document";
export default function Document() {
return (
<Html lang="en">
<Head />
<body className="antialiased">
<Main />
<NextScript />
</body>
</Html>
);
}

13
src/pages/api/hello.ts Normal file
View File

@@ -0,0 +1,13 @@
// Next.js API route support: https://nextjs.org/docs/api-routes/introduction
import type { NextApiRequest, NextApiResponse } from "next";
type Data = {
name: string;
};
export default function handler(
req: NextApiRequest,
res: NextApiResponse<Data>,
) {
res.status(200).json({ name: "John Doe" });
}

9
src/pages/index.tsx Normal file
View File

@@ -0,0 +1,9 @@
import { Button } from "@mui/material";
export default function Home() {
return (
<div>
<Button>Say woah!</Button>
</div>
);
}

3
src/styles/globals.css Normal file
View File

@@ -0,0 +1,3 @@
@tailwind base;
@tailwind components;
@tailwind utilities;