Adding the TaskItem class and API controller

Learn how to add a C# class and API controllers to our Blazor WebAssembly app.

We need to add the TaskItem class. We do this as follows:

  1. Right-click the TaskManager.Shared project and select the “Add, Class” option from the menu.
  2. Name the new class TaskItem.
  3. Click the “Add” button.
  4. Make the class public by adding the public modifier:

Get hands-on with 1200+ tech skills courses.