git clone [email protected]:FaZeRs/portfolio.git
.github
└─ workflows
└─ CI with pnpm cache setup
.vscode
└─ Recommended extensions and settings for VSCode users
apps
└─ web
├─ Next.js 14
├─ React 18
├─ Tailwind CSS
└─ E2E Typesafe API Server & Client
packages
├─ api
| └─ tRPC v11 router definition
├─ auth
| └─ Authentication using next-auth.
├─ db
| └─ Typesafe db calls using Drizzle & Supabase
├─ transactional
| └─ Email, SMS, and other transactional services
├─ ui
| └─ Start of a UI package for the webapp using shadcn-ui
└─ validators
└─ Shared validators using zod
tooling
├─ eslint
| └─ shared, fine-grained, eslint presets
├─ prettier
| └─ shared prettier configuration
├─ tailwind
| └─ shared tailwind configuration
└─ typescript
└─ shared tsconfig you can extend from
In this template, we use
@acme
as a placeholder for package names. As a user, you might want to replace it with your own organization or project name. You can use find-and-replace to change all the instances of@acme
to something like@my-company
or@project-name
.
Note The db package is preconfigured to use Supabase and is edge-bound with the Vercel Postgres driver. If you're using something else, make the necessary modifications to the schema as well as the client and the drizzle config. If you want to switch to non-edge database driver, remove
export const runtime = "edge";
from all pages and api routes.
To get it running, follow the steps below:
# Install dependencies
pnpm i
# Configure environment variables
# There is an `.env.example` in the root directory you can use for reference
cp .env.example .env
# Push the Drizzle schema to the database
pnpm db:push
Let's deploy the Next.js application to Vercel. If you've never deployed a Turborepo app there, don't worry, the steps are quite straightforward. You can also read the official Turborepo guide on deploying to Vercel.
-
Create a new project on Vercel, select the
apps/web
folder as the root directory. Vercel's zero-config system should handle all configurations for you. -
Add your
DATABASE_URL
environment variable. -
Done! Your app should successfully deploy.