Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/sarmad426/mern-todo-app

Mern Stack Todo app. MongoDB | Express js | React js | Node js
https://github.com/sarmad426/mern-todo-app

express mern-stack mongodb node react todo-app typescript

Last synced: 5 days ago
JSON representation

Mern Stack Todo app. MongoDB | Express js | React js | Node js

Awesome Lists containing this project

README

        

# MERN Stack Todo app

This is a full stack Todo app built with the MERN stack. It uses **Mongo DB**, **Express js**, **React js** and **Node js**. It uses typescript as a primary language for both the frontend and backend.

## Setup the project

Make sure you have pnpm an mongo db compass installed in your system.

```bash
git clone https://github.com/sarmad426/mern-todo-app.git
```

Go to the project directory

```bash
cd mern-todo-app
```

**Setup the backend**:

```bash
cd backend
pnpm i
pnpm build
```

**Run the backend**:

```bash
pnpm start
```

**Setup the frontend**:

```bash
cd frontend
pnpm i
```

**Run the frontend**:

```bash
pnpm dev
```

## Setup the MERN project from scratch

```bash
md frontend backend
```

**Setup the backend:**

```bash
cd backend
pnpm init -y
```

**Add required dependencies:**

```bash
pnpm add express mongoose dotenv
pnpm add -D nodemon
pnpm add typescript ts-node @types/node @types/express
pnpm dlx tsc --init
```

**Setup the front end:**

```bash
cd frontend
pnpm create vite .
pnpm i
```

**Run the backend:**

```bash
pnpm start
```

It will start listening at port 5000. Test it at

**Run the frontend:**

```bash
pnpm dev
```

Go to

Todo app setup successful. 🎉