Adding React to an existing ASP.Net MVC project — Part 3: The API

Part 3: The API

Paddy Guest
4 min readFeb 19, 2022

This builds on parts 1 and 2 which can be found here:

In this part we are going to look at adding the API to the project using an API Controller. In future parts of the series this will become multiple controllers as adding all the endpoints for a project into a single file makes it unmanageable.

The first thing we need to do is to add the controller itself. Right-click the “Controllers” folder, select Add → Controller

Leave the default options and click “Add”

--

--

Paddy Guest
Paddy Guest

Written by Paddy Guest

I am a software developer, business manager, amateur mixologist and cooking enthusiast.

Responses (1)