Controller Scoped Model Binding in ASP.NET Core

Want to avoid [FromBody] attributes everywhere? Don’t want to use [ApiController] strict conventions? Don’t want to apply IInputFormatter’s globally?…

Read this article

How to register MVC controllers shipped with a class library in ASP.NET Core

In many cases you’ll want to ship MVC controllers, possibly views or taghelpers, etc… as part of your class library. To do this correctly you’ll want to add your assembly to ASP.NET’s “Application…

Read this article

Need to remove an auto-routed controller in Umbraco?

Umbraco will auto-route some controllers automatically. These controllers are any MVC SurfaceControllers or WebApi UmbracoApiController types discovered during startup. There might be some cases where…

Read this article

Model binding with FromServices in ASP.Net 5

Here’s a pretty nifty feature I found in ASP.Net 5 – you can construct your model during model binding with IoC without any additional work. This is available on the dev branch on GitHub and is based…

Read this article

ASP.Net 5 Re-learning a few things (part 2)

This is part 2 of a series of posts about some fundamental changes in ASP.Net 5 that we’ll all need to re-learn (or un-learn!) Part 1: http://shazwazza.com/post/aspnet-5-re-learning-a-few-things-part-…

Read this article

ClientDependency 1.8 released

.nuget-badge code {background-color: #202020;border: 4px solid silver;border-bottom-left-radius: 5px 5px;border-bottom-right-radius: 5px 5px;border-top-left-radius: 5px 5px;border-top-right-radius: 5…

Read this article

Custom MVC routes within the Umbraco pipeline

A while ago I wrote a post on how to do custom MVC routing in Umbraco, though the end result wasn’t quite ideal. There were a few tricks required and It wasn’t perfect since there were problems with r…

Read this article

Multi targeting a single .Net project to build for different framework versions

Consider this scenario: I have a project that relies on ASP.Net MVC and currently this project is built against the .Net framework 4.0 and MVC 4 I want to support MVC 5 for this project To support…

Read this article

Custom MVC routing in Umbraco

This post will describe how you can declare your own custom MVC routes in order to execute your own custom controllers in Umbraco but still be able to render Umbraco views with the same model that Umb…

Read this article

Razor + dynamic + internal + interface & the 'object' does not contain a definition for 'xxxx' exception

I’ve come across this strange issue and decided to blog about it since I can’t figure out exactly why this is happening it is clearly something to do with the DLR and interfaces. First, if you are get…

Read this article