Hi,
Today, I saw that ASP.NET Web API now has [JsonResult](https://aspnetwebstack.codeplex.com/SourceControl/latest#src/System.Web.Http/Results/JsonResult.cs) and even a Json method on ApiController. Just what we needed all along! I cannot think of any words which would describe my reaction when I saw it but maybe this picture can give a hint: [http://i.imgur.com/Bp9an.gif](http://i.imgur.com/Bp9an.gif)
Why on God's green earth do we have this? Why do we try to mess with HTTP and beautiful content negotiation that ASP.NET Web API framework has? This's harm! Please, just remove it and it will be nothing but a commit history.
Thanks!
Comments: @tugberk: Just to clarify on one point...It's true that returning specific formatted result from an action would make con-neg useless, but we have scenarios where users wanted this kind of functionality for specific actions for whatever reason, so I think providing a way for them to do this is necessary. My only point is to not have a new type called JsonResult for this purpose(as however this scenario is not so common), but instead use already present action results.
Today, I saw that ASP.NET Web API now has [JsonResult](https://aspnetwebstack.codeplex.com/SourceControl/latest#src/System.Web.Http/Results/JsonResult.cs) and even a Json method on ApiController. Just what we needed all along! I cannot think of any words which would describe my reaction when I saw it but maybe this picture can give a hint: [http://i.imgur.com/Bp9an.gif](http://i.imgur.com/Bp9an.gif)
Why on God's green earth do we have this? Why do we try to mess with HTTP and beautiful content negotiation that ASP.NET Web API framework has? This's harm! Please, just remove it and it will be nothing but a commit history.
Thanks!
Comments: @tugberk: Just to clarify on one point...It's true that returning specific formatted result from an action would make con-neg useless, but we have scenarios where users wanted this kind of functionality for specific actions for whatever reason, so I think providing a way for them to do this is necessary. My only point is to not have a new type called JsonResult for this purpose(as however this scenario is not so common), but instead use already present action results.