Web Boilerplate screenshot

Web Boilerplate

Author Avatar Theme by Ditadi
Updated: 7 Jun 2023
53 Stars

Boilerplate with NextJS, RSC, Clerk, Turso, Drizzle and much more things.

Categories

Overview

The Ditadi Boilerplate is a repository created for testing and experimenting with new web development techniques and libraries. It aims to provide a starting point for projects involving Turborepo, NextJS App Routing, Server Actions, useOptimistic, useFormStatus, React Server Components, Tailwind CSS, shadcn/UI, Drizzle, TursoDB, Clerk, Eslint, Prettier, CC, Husky, and more. The repository will be regularly updated with new additions.

Features

  • Turborepo: A tool for managing monorepo setups and managing dependencies.
  • NextJS App Routing: Enables easy routing and navigation within NextJS applications, including parallel routing support.
  • Server Actions: Provides a framework for defining server actions in web applications.
  • useOptimistic: A custom hook for handling optimistic updates in React applications.
  • useFormStatus: A hook for tracking the status (touched, changed, and submitted) of form fields in React applications.
  • React Server Components: Allows for server-side rendering of React components.
  • Tailwind CSS: A utility-first CSS framework for quickly building custom designs.
  • shadcn/UIDrizzle: A library that extends the Drizzle library for handling blockchain integration in React applications.

Installation

  1. To run the application, the following keys need to be generated:

    • TursoDB: Download the turso-cli using brew install chiselstrike/tap/turso or curl -sSfL https://get.tur.so/install.sh | bash. Create a database using turso db create {{/*database_name*/}} and retrieve the DATABASE_URL generated. Store this value in the .env file.
    • ClerkJS: Create an account on Clerk and retrieve the NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY and CLERK_SECRET_KEY. Add these configurations to the Clerk path.
  2. Run the following migration steps:

    • Generate the migration using npx drizzle-kit generate:sqlite
    • Push the migration to the database using turso db shell {{/*database_name*/}} < migrations/{{/*migration_file*/}}.sql
    • Create a .env file in the root directory and add the necessary keys.
  3. Install the dependencies and run the app:

    • Run pnpm install in the root directory to install the dependencies.
    • Run pnpm dev to start the application.
    • Access the application on http://localhost:3000.

Summary

The Ditadi Boilerplate is a repository designed to facilitate the implementation of various web development techniques and libraries. It includes features such as Turborepo, NextJS App Routing, Server Actions, and more. The installation guide provides step-by-step instructions for setting up the boilerplate.