Infolink

 

Search This Blog

Showing posts with label How to Detect Errors of Our ASP.NET MVC Views on Compile Time. Show all posts
Showing posts with label How to Detect Errors of Our ASP.NET MVC Views on Compile Time. Show all posts

Oct 21, 2012

How to Detect Errors of Our ASP.NET MVC Views on Compile Time

I have simple ASP.NET MVC 4 internet application which we get out of the box (Things that I will show can be applied with ASP.NET MVC 3 as well). Then I will put a bug inside the index view of my home controller :

@{
    var poo = "bar"
    }

<h3>We suggest the following:</h3>
As you can see it is not a valid code. So it should fail on both compile time and runtime, right? Let’s build the project first :

Error1
Related Posts Plugin for WordPress, Blogger...