- This post is going to cover adding a React project to the existing using the React template that is now built into Visual Studio.
- The goal for the React project in this initial post will be to connect to the contacts API and download a list of contacts and render that to the screen.
- The following is the resulting React project in the context of the full solution.
- Next, make sure and run npm install from a command prompt in the React project’s directory to ensure all the npm packages get restored.
- Since this is my first time working with React I took the FetchData.tsx file and copied the contents and used that as the starting point for my contact list.
In the past, I have done some exploration on Aurelia and Angular via the ASP.NET Core Basics series. This post is going to take a similar approach as I start doing some exploration with React. The code for the project will be in the same repo as the previous basics examples and will be utilizing the same API to pull data. The code before adding the React project can be found here.
Continue reading “ASP.NET Core Basics: React with an API – Eric L. Anderson”