Skip to content

mtadakuma/React_Net_Contacts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

React and .NET with MongoDB Contacts Store

This is a project for a contacts storing application with React as it's frontend and a .NET REST API as the backend, this project also persists the information in MongoDB and includes the Swagger documentation for the Rest API calls.

demo_contacts

Tech Stack

Client: React, CSS.

Server: .NET, MongoDB, Swagger

Dependencies

  • react
  • react-router-dom
  • dotnet
  • MongoDB Compass
  • mongoDB Shell (mongosh)

Run Locally

Instructions for MongoDB:

Open mongosh and add the path

  mongodb://localhost:27017

Then add the following code to create a new database

  use ContactsStore

Create a collection

  db.createCollection('Contacts')

Insert two registries to the collection

  db.Contacts.insertMany([{ "Username": "JosePerez", "Email": "jperez@gmail.com", "Telefono": "02231512345678" }, { "Username": "PaulaLopez", "Email": "plopez@gmail.com", "Telefono": "0111587654321" }])

Check if the registries were correctly inserted

  db.Contacts.find().pretty()

Running the project:

Clone the project

  git clone https://github.com/mtadakuma/React_Net_Contacts.git

To run the serverside webapi:

Go to the project directory

  cd React_NET_Contacts

Go to WebApi folder

  cd ContactsStoreApi

Run the server side Api

  dotnet run

To run the clientside in React:

Go to the project directory

  cd React_NET_Contacts

Go to React folder

  cd client

Install dependencies

  npm install

Start the server

  npm run start

To check Swagger documentation:

While the serverside webapi is running go to the following path

https://localhost:7235/swagger/index.html

or

http://localhost:5021/swagger/index.html

Troubleshooting

In case any error appears make sure to have the following softwares

Authors

About

Contacts project with React(Frontend) .NET(Backend) and MongoDB

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors