O'Reilly logo

Instant Nancy Web Development by Christian Horsdal

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Adding views (Intermediate)

In this recipe, we will add a couple of Razor views to the application built in the previous recipes. We will see how our module code controls which view to use and how to set up tests for the views.

Getting ready

You need the code built until the Content negotiation and more model binding (Advanced) recipe. If you haven't coded along, you can start from the code for the Content negotiation and more model binding (Advanced) recipe in the code download.

I will assume you have a working knowledge of Razor, so if you are new to Razor, you should probably brush up on Razor before diving into this recipe.

How to do it...

The following steps will help you add views to your application:

  1. As always, we start by adding a test. This ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required