Skip to content
/ react-starter-kit Public template

The web's most popular Jamstack front-end template (boilerplate) for building web applications with React

License

Notifications You must be signed in to change notification settings

kriasoft/react-starter-kit

Repository files navigation

React Starter Kit

So, you want to build a modern web app but don't want to spend the next two weeks configuring everything? You've come to the right place. This React Starter Kit is a batteries-included, production-ready boilerplate that lets you skip the boring parts and get straight to building.

It's built on a modern, edge-first stack that's fast, type-safe, and frankly, a joy to work with. Whether you're building a weekend project or the next big thing, we've got your back.

Features

  • Blazing Fast Everything: Powered by Bun, from the backend server to the scripts. It's fast. Like, "go get a coffee and it's already done" fast.
  • Full-Stack Type Safety: With TypeScript and tRPC, you can say goodbye to runtime errors. If it compiles, it works (usually).
  • Modern Frontend: Built with React 19, TanStack Router for type-safe routing, and Tailwind CSS v4 for styling. Your UI will be snappy and look good doing it.
  • Edge-First Architecture: Deploy to Cloudflare Workers for incredible performance and scalability. Your app will be everywhere, all at once.
  • Database Included: Comes with Drizzle ORM and a pre-configured schema for multi-tenant applications. No more writing SQL by hand unless you really, really want to.
  • Top-Notch DX: Pre-configured with ESLint, Prettier, and VSCode settings to keep your code clean and your team happy. Less arguing about tabs vs. spaces, more building cool stuff.

    


This project was bootstrapped with React Starter Kit. Be sure to join our Discord channel for assistance.

Directory Structure

├──api — tRPC API server built with Hono
├──app — Web application front-end built with React and Tailwind CSS
├──core — Shared code, types, and WebSocket logic used across the stack
├──db — Database schema, migrations, and seeds using Drizzle ORM
├──edge — Cloudflare Worker entry point for handling requests at the edge
├──scripts — Various build and automation scripts
├──tsconfig.base.json — The common/shared TypeScript configuration for the monorepo
└──wrangler.jsonc — Configuration file for Cloudflare Workers

Tech Stack

Requirements

Getting Started

Generate a new project from this template, clone it, install project dependencies, update the environment variables found in .env / .env.local, and start hacking:

# Clone the repository
git clone https://github.com/kriasoft/react-starter-kit.git example
cd ./example

# Launch the front-end app
bun --cwd app start

# Launch the backend API server
bun --cwd edge build --watch
bun wrangler dev

# Migrate the database
bun --cwd db migrate

Your frontend will be running at http://localhost:5173/, and the backend API will be on the port from wrangler dev (usually 8787). Open the frontend URL in your browser to see the app in action.

How to Deploy

Ensure that all the environment variables in .env/.env.local files and Wrangler configuration in wrangler.json file are up-to-date.

If you haven't done it already, push any secret values you may need to CF Workers environment by running bun wrangler secret put <NAME> [--env #0].

Finally build and deploy the app by running:

bun --cwd app build
bun --cwd edge build
bun wrangler deploy

Contributors 👨‍💻

              

Backers 💰

              

Related Projects

How to Contribute

Anyone and everyone is welcome to contribute. Start by checking out the list of open issues marked help wanted. However, if you decide to get involved, please take a moment to review the guidelines.

License

Copyright © 2014-present Kriasoft. This source code is licensed under the MIT license found in the LICENSE file.


Made with ♥ by Konstantin Tarkus (@koistya, blog) and contributors.

Sponsor this project

 

Contributors 6