Skip to content

A Todo List web application built with TypeScript, NestJS, Prisma PostgreSQL, and Vite (React), featuring JWT-based authentication.

Notifications You must be signed in to change notification settings

arcdevoff/todolist

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

screen

📝 Todo List App

A full-stack Todo List application built with TypeScript, NestJS, Prisma, PostgreSQL, and Vite (React).
Features user authentication with JWT, task management, and secure API integration.


⚡ Stack

  • Frontend: Vite + React + TailwindCSS
  • Backend: NestJS (TypeScript)
  • Database: PostgreSQL with Prisma ORM
  • Auth: JWT (JSON Web Tokens)

📦 Installation

Clone the repository and install dependencies:

git clone https://github.com/arcdevoff/todolist.git
cd todolist

Install dependencies for backend and frontend:

# Backend
cd server
npm install

# Frontend
cd client
npm install

⚙️ Environment Variables

Create .env files:

Backend (server/.env)

DATABASE_URL="postgresql://USER:PASSWORD@localhost:5432/todolist"

PORT=3000
NODE_ENV=development

CLIENT_URL=http://localhost:5173

ACCESS_TOKEN_SECRET=replace_this_access_secret
REFRESH_TOKEN_SECRET=replace_this_refresh_secret
ACCESS_TOKEN_EXPIRES_IN=15m
REFRESH_TOKEN_EXPIRES_IN=7d

Frontend (client/.env)

VITE_API_URL="http://localhost:3000"
VITE_PORT=5173

🗄️ Database (Prisma + PostgreSQL)

  1. Make sure PostgreSQL is running.
  2. Push schema to database:
    cd server
    npx prisma migrate dev --name init
  3. Generate Prisma client:
    npx prisma generate

🚀 Running the Project

Backend (NestJS)

cd server
# development
npm run start:dev

# production
npm run build
npm run start:prod

Frontend (Vite)

cd client
# development
npm run dev

# production build
npm run build
npm run preview

🌐 Access

  • Frontend: http://localhost:5173
  • Backend API: http://localhost:3000

🛠️ Scripts

Backend

  • npm run start:dev → run NestJS in dev mode
  • npm run start:prod → run NestJS in production
  • npx prisma studio → open Prisma Studio (DB UI)

Frontend

  • npm run dev → run Vite dev server
  • npm run build → build for production
  • npm run preview → preview production build

📸 Features

  • ✅ JWT Authentication (register/login)
  • ✅ User-based tasks
  • ✅ Secure API with NestJS guards
  • ✅ Database schema with Prisma
  • ✅ Modern frontend with React + TailwindCSS

About

A Todo List web application built with TypeScript, NestJS, Prisma PostgreSQL, and Vite (React), featuring JWT-based authentication.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published