Skip to content

React.Js, .Net Core(2.2) Web Api with in-memory/Sql db (Entity Framework code first)

Notifications You must be signed in to change notification settings

NileshSP/ReactJsAspnetEFCodeFirstSql

Repository files navigation

React.Js, .Net Core(2.2) Web Api using Entity Framework code first interfacing In-memory/MS-Sql db

Project showcases React.js frontend UI consuming data from the i-memory/sql database which communicates using .Net Core by exposing Web Api endpoints (for Json output) supplemented by entity framework scaffolded models


Steps to get the project running

Pre-requisites:

  1. .Net Core 2.2 SDK
  2. Visual Studio Code or Recommended - Visual Studio Community editon version 15.9.1 or later editor

Clone the current repository locally as git clone https://github.com/NileshSP/ReactJsAspnetEFCodeFirstSql.git


Steps: using Visual Studio community edition editor

  1. Open the solution file (ReactJsAspnetEFSqlSln.sln) available in the root folder of the downloaded repository
  2. Await until the project is ready as per the status shown in taskbar which loads required packages in the background
  3. Hit -> F5 or select 'Debug -> Start Debugging' option to run the project

Steps: using Visual Studio code editor

  1. Open the root folder of the downloaded repository
  2. Await until the project is ready as per the status shown in taskbar which loads required packages in the background
  3. Open Terminal - 'Terminal -> New Terminal' and execute commands as cd ReactJsAspnetEFSql & dotnet build & dotnet run sequentially OR
  4. Hit -> F5 or select 'Debug -> Start Debugging' option to run the project

Once the project is build and run, a browser page would be presented with navigation options on right wherein 'Websites data' option contains functionality related to data access from in-memory/sql database

alt text

Root folder contents:

  1. ReactJsAspnetEFSql folder: contains frontend UI built using React.js(in ClientApp folder) and .Net Core Web Api endpoints
  2. ReactJsAspnetEFSqlTests folder: unit tests for Web Api Endpoints
  3. ReactJsAspnetEFSqlSln.sln solution file
  4. Readme.md file for project information