create-stackkit-app 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -94
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/lib/create-project.d.ts +0 -1
- package/dist/lib/create-project.js +124 -67
- package/dist/lib/template-composer.d.ts +0 -1
- package/dist/lib/template-composer.js +0 -2
- package/modules/auth/authjs-express/files/lib/auth.ts +40 -0
- package/modules/auth/authjs-express/files/routes/auth.ts +12 -0
- package/modules/auth/authjs-express/module.json +39 -0
- package/modules/auth/authjs-nextjs/files/lib/auth.ts +43 -0
- package/modules/auth/authjs-nextjs/module.json +38 -0
- package/modules/auth/better-auth-express/files/lib/auth.ts +16 -0
- package/modules/auth/better-auth-express/files/routes/auth.ts +12 -0
- package/modules/auth/better-auth-express/module.json +38 -0
- package/{templates/auth/better-auth-nextjs/app → modules/auth/better-auth-nextjs/files}/api/auth/[...all]/route.ts +1 -0
- package/modules/auth/better-auth-nextjs/files/lib/auth.ts +26 -0
- package/modules/auth/better-auth-nextjs/module.json +41 -0
- package/modules/auth/better-auth-react/files/lib/auth-client.ts +9 -0
- package/modules/auth/better-auth-react/module.json +26 -0
- package/modules/auth/clerk-express/files/lib/auth.ts +7 -0
- package/modules/auth/clerk-express/module.json +19 -0
- package/modules/auth/clerk-nextjs/files/lib/auth-provider.tsx +5 -0
- package/modules/auth/clerk-nextjs/files/middleware.ts +9 -0
- package/modules/auth/clerk-nextjs/module.json +27 -0
- package/modules/auth/clerk-react/files/lib/auth-provider.tsx +15 -0
- package/modules/auth/clerk-react/module.json +18 -0
- package/modules/auth/nextauth/files/app-router/api/auth/[...nextauth]/route.ts +6 -0
- package/modules/auth/nextauth/files/lib/auth.ts +82 -0
- package/modules/auth/nextauth/files/pages-router/api/auth/[...nextauth].ts +4 -0
- package/modules/auth/nextauth/module.json +50 -0
- package/modules/database/drizzle-postgresql/files/drizzle.config.ts +10 -0
- package/modules/database/drizzle-postgresql/files/lib/db.ts +7 -0
- package/modules/database/drizzle-postgresql/files/lib/schema.ts +8 -0
- package/modules/database/drizzle-postgresql/module.json +34 -0
- package/modules/database/mongoose-mongodb/files/lib/db.ts +40 -0
- package/modules/database/mongoose-mongodb/module.json +17 -0
- package/{templates/databases/prisma-mongodb → modules/database/prisma-mongodb/files}/lib/db.ts +2 -6
- package/{templates/databases/prisma-mongodb → modules/database/prisma-mongodb/files}/prisma/schema.prisma +1 -0
- package/modules/database/prisma-mongodb/module.json +36 -0
- package/{templates/databases/prisma-postgresql → modules/database/prisma-postgresql/files}/lib/db.ts +2 -6
- package/{templates/databases/prisma-postgresql → modules/database/prisma-postgresql/files}/prisma/schema.prisma +1 -0
- package/modules/database/prisma-postgresql/module.json +36 -0
- package/package.json +7 -5
- package/templates/bases/nextjs-base/README.md +36 -0
- package/templates/bases/nextjs-base/app/favicon.ico +0 -0
- package/templates/bases/nextjs-base/app/globals.css +26 -3
- package/templates/bases/nextjs-base/app/layout.tsx +21 -6
- package/templates/bases/nextjs-base/app/page.tsx +61 -4
- package/templates/bases/nextjs-base/eslint.config.mjs +18 -0
- package/templates/bases/nextjs-base/next.config.ts +4 -2
- package/templates/bases/nextjs-base/package-lock.json +6538 -0
- package/templates/bases/nextjs-base/package.json +12 -10
- package/templates/bases/nextjs-base/postcss.config.mjs +7 -0
- package/templates/bases/nextjs-base/public/file.svg +1 -0
- package/templates/bases/nextjs-base/public/globe.svg +1 -0
- package/templates/bases/nextjs-base/public/next.svg +1 -0
- package/templates/bases/nextjs-base/public/vercel.svg +1 -0
- package/templates/bases/nextjs-base/public/window.svg +1 -0
- package/templates/bases/nextjs-base/template.json +12 -1
- package/templates/bases/nextjs-base/tsconfig.json +9 -2
- package/templates/bases/react-vite-base/index.html +13 -0
- package/templates/bases/react-vite-base/package.json +27 -0
- package/templates/bases/react-vite-base/src/App.css +14 -0
- package/templates/bases/react-vite-base/src/App.tsx +23 -0
- package/templates/bases/react-vite-base/src/index.css +68 -0
- package/templates/bases/react-vite-base/src/main.tsx +10 -0
- package/templates/bases/react-vite-base/src/vite-env.d.ts +1 -0
- package/templates/bases/react-vite-base/template.json +5 -0
- package/templates/bases/react-vite-base/tsconfig.json +21 -0
- package/templates/bases/react-vite-base/vite.config.ts +7 -0
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/lib/create-project.d.ts.map +0 -1
- package/dist/lib/create-project.js.map +0 -1
- package/dist/lib/template-composer.d.ts.map +0 -1
- package/dist/lib/template-composer.js.map +0 -1
- package/templates/auth/better-auth-express/config.json +0 -18
- package/templates/auth/better-auth-express/src/lib/auth.ts +0 -12
- package/templates/auth/better-auth-express/src/routes/auth.ts +0 -10
- package/templates/auth/better-auth-nextjs/config.json +0 -18
- package/templates/auth/better-auth-nextjs/lib/auth.ts +0 -14
- package/templates/auth/nextauth/config.json +0 -18
- package/templates/auth/nextauth/lib/auth.ts +0 -31
- package/templates/bases/nextjs-base/.eslintrc.json +0 -3
- package/templates/databases/prisma-mongodb/config.json +0 -21
- package/templates/databases/prisma-postgresql/config.json +0 -22
- /package/{templates/auth/nextauth/app → modules/auth/authjs-nextjs/files}/api/auth/[...nextauth]/route.ts +0 -0
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
This is a [Next.js](https://nextjs.org) project bootstrapped with [`create-next-app`](https://nextjs.org/docs/app/api-reference/cli/create-next-app).
|
|
2
|
+
|
|
3
|
+
## Getting Started
|
|
4
|
+
|
|
5
|
+
First, run the development server:
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm run dev
|
|
9
|
+
# or
|
|
10
|
+
yarn dev
|
|
11
|
+
# or
|
|
12
|
+
pnpm dev
|
|
13
|
+
# or
|
|
14
|
+
bun dev
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.
|
|
18
|
+
|
|
19
|
+
You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.
|
|
20
|
+
|
|
21
|
+
This project uses [`next/font`](https://nextjs.org/docs/app/building-your-application/optimizing/fonts) to automatically optimize and load [Geist](https://vercel.com/font), a new font family for Vercel.
|
|
22
|
+
|
|
23
|
+
## Learn More
|
|
24
|
+
|
|
25
|
+
To learn more about Next.js, take a look at the following resources:
|
|
26
|
+
|
|
27
|
+
- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
|
|
28
|
+
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.
|
|
29
|
+
|
|
30
|
+
You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js) - your feedback and contributions are welcome!
|
|
31
|
+
|
|
32
|
+
## Deploy on Vercel
|
|
33
|
+
|
|
34
|
+
The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.
|
|
35
|
+
|
|
36
|
+
Check out our [Next.js deployment documentation](https://nextjs.org/docs/app/building-your-application/deploying) for more details.
|
|
Binary file
|
|
@@ -1,3 +1,26 @@
|
|
|
1
|
-
@
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
@import "tailwindcss";
|
|
2
|
+
|
|
3
|
+
:root {
|
|
4
|
+
--background: #ffffff;
|
|
5
|
+
--foreground: #171717;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
@theme inline {
|
|
9
|
+
--color-background: var(--background);
|
|
10
|
+
--color-foreground: var(--foreground);
|
|
11
|
+
--font-sans: var(--font-geist-sans);
|
|
12
|
+
--font-mono: var(--font-geist-mono);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
@media (prefers-color-scheme: dark) {
|
|
16
|
+
:root {
|
|
17
|
+
--background: #0a0a0a;
|
|
18
|
+
--foreground: #ededed;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
body {
|
|
23
|
+
background: var(--background);
|
|
24
|
+
color: var(--foreground);
|
|
25
|
+
font-family: Arial, Helvetica, sans-serif;
|
|
26
|
+
}
|
|
@@ -1,19 +1,34 @@
|
|
|
1
|
-
import type { Metadata } from
|
|
2
|
-
import
|
|
1
|
+
import type { Metadata } from "next";
|
|
2
|
+
import { Geist, Geist_Mono } from "next/font/google";
|
|
3
|
+
import "./globals.css";
|
|
4
|
+
|
|
5
|
+
const geistSans = Geist({
|
|
6
|
+
variable: "--font-geist-sans",
|
|
7
|
+
subsets: ["latin"],
|
|
8
|
+
});
|
|
9
|
+
|
|
10
|
+
const geistMono = Geist_Mono({
|
|
11
|
+
variable: "--font-geist-mono",
|
|
12
|
+
subsets: ["latin"],
|
|
13
|
+
});
|
|
3
14
|
|
|
4
15
|
export const metadata: Metadata = {
|
|
5
|
-
title:
|
|
6
|
-
description:
|
|
16
|
+
title: "Create Next App",
|
|
17
|
+
description: "Generated by create next app",
|
|
7
18
|
};
|
|
8
19
|
|
|
9
20
|
export default function RootLayout({
|
|
10
21
|
children,
|
|
11
22
|
}: Readonly<{
|
|
12
|
-
children: React.
|
|
23
|
+
children: React.ReactNode;
|
|
13
24
|
}>) {
|
|
14
25
|
return (
|
|
15
26
|
<html lang="en">
|
|
16
|
-
<body
|
|
27
|
+
<body
|
|
28
|
+
className={`${geistSans.variable} ${geistMono.variable} antialiased`}
|
|
29
|
+
>
|
|
30
|
+
{children}
|
|
31
|
+
</body>
|
|
17
32
|
</html>
|
|
18
33
|
);
|
|
19
34
|
}
|
|
@@ -1,8 +1,65 @@
|
|
|
1
|
+
import Image from "next/image";
|
|
2
|
+
|
|
1
3
|
export default function Home() {
|
|
2
4
|
return (
|
|
3
|
-
<
|
|
4
|
-
<
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
<div className="flex min-h-screen items-center justify-center bg-zinc-50 font-sans dark:bg-black">
|
|
6
|
+
<main className="flex min-h-screen w-full max-w-3xl flex-col items-center justify-between py-32 px-16 bg-white dark:bg-black sm:items-start">
|
|
7
|
+
<Image
|
|
8
|
+
className="dark:invert"
|
|
9
|
+
src="/next.svg"
|
|
10
|
+
alt="Next.js logo"
|
|
11
|
+
width={100}
|
|
12
|
+
height={20}
|
|
13
|
+
priority
|
|
14
|
+
/>
|
|
15
|
+
<div className="flex flex-col items-center gap-6 text-center sm:items-start sm:text-left">
|
|
16
|
+
<h1 className="max-w-xs text-3xl font-semibold leading-10 tracking-tight text-black dark:text-zinc-50">
|
|
17
|
+
To get started, edit the page.tsx file.
|
|
18
|
+
</h1>
|
|
19
|
+
<p className="max-w-md text-lg leading-8 text-zinc-600 dark:text-zinc-400">
|
|
20
|
+
Looking for a starting point or more instructions? Head over to{" "}
|
|
21
|
+
<a
|
|
22
|
+
href="https://vercel.com/templates?framework=next.js&utm_source=create-next-app&utm_medium=appdir-template-tw&utm_campaign=create-next-app"
|
|
23
|
+
className="font-medium text-zinc-950 dark:text-zinc-50"
|
|
24
|
+
>
|
|
25
|
+
Templates
|
|
26
|
+
</a>{" "}
|
|
27
|
+
or the{" "}
|
|
28
|
+
<a
|
|
29
|
+
href="https://nextjs.org/learn?utm_source=create-next-app&utm_medium=appdir-template-tw&utm_campaign=create-next-app"
|
|
30
|
+
className="font-medium text-zinc-950 dark:text-zinc-50"
|
|
31
|
+
>
|
|
32
|
+
Learning
|
|
33
|
+
</a>{" "}
|
|
34
|
+
center.
|
|
35
|
+
</p>
|
|
36
|
+
</div>
|
|
37
|
+
<div className="flex flex-col gap-4 text-base font-medium sm:flex-row">
|
|
38
|
+
<a
|
|
39
|
+
className="flex h-12 w-full items-center justify-center gap-2 rounded-full bg-foreground px-5 text-background transition-colors hover:bg-[#383838] dark:hover:bg-[#ccc] md:w-[158px]"
|
|
40
|
+
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=appdir-template-tw&utm_campaign=create-next-app"
|
|
41
|
+
target="_blank"
|
|
42
|
+
rel="noopener noreferrer"
|
|
43
|
+
>
|
|
44
|
+
<Image
|
|
45
|
+
className="dark:invert"
|
|
46
|
+
src="/vercel.svg"
|
|
47
|
+
alt="Vercel logomark"
|
|
48
|
+
width={16}
|
|
49
|
+
height={16}
|
|
50
|
+
/>
|
|
51
|
+
Deploy Now
|
|
52
|
+
</a>
|
|
53
|
+
<a
|
|
54
|
+
className="flex h-12 w-full items-center justify-center rounded-full border border-solid border-black/[.08] px-5 transition-colors hover:border-transparent hover:bg-black/[.04] dark:border-white/[.145] dark:hover:bg-[#1a1a1a] md:w-[158px]"
|
|
55
|
+
href="https://nextjs.org/docs?utm_source=create-next-app&utm_medium=appdir-template-tw&utm_campaign=create-next-app"
|
|
56
|
+
target="_blank"
|
|
57
|
+
rel="noopener noreferrer"
|
|
58
|
+
>
|
|
59
|
+
Documentation
|
|
60
|
+
</a>
|
|
61
|
+
</div>
|
|
62
|
+
</main>
|
|
63
|
+
</div>
|
|
7
64
|
);
|
|
8
65
|
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { defineConfig, globalIgnores } from "eslint/config";
|
|
2
|
+
import nextVitals from "eslint-config-next/core-web-vitals";
|
|
3
|
+
import nextTs from "eslint-config-next/typescript";
|
|
4
|
+
|
|
5
|
+
const eslintConfig = defineConfig([
|
|
6
|
+
...nextVitals,
|
|
7
|
+
...nextTs,
|
|
8
|
+
// Override default ignores of eslint-config-next.
|
|
9
|
+
globalIgnores([
|
|
10
|
+
// Default ignores of eslint-config-next:
|
|
11
|
+
".next/**",
|
|
12
|
+
"out/**",
|
|
13
|
+
"build/**",
|
|
14
|
+
"next-env.d.ts",
|
|
15
|
+
]),
|
|
16
|
+
]);
|
|
17
|
+
|
|
18
|
+
export default eslintConfig;
|