{"id":269,"date":"2011-03-27T20:50:37","date_gmt":"2011-03-27T19:50:37","guid":{"rendered":"http:\/\/blog.repsaj.nl\/?p=269"},"modified":"2011-03-27T20:52:46","modified_gmt":"2011-03-27T19:52:46","slug":"struggling-with-asp-net-mvc-2","status":"publish","type":"post","link":"http:\/\/blog.repsaj.nl\/index.php\/2011\/03\/struggling-with-asp-net-mvc-2\/","title":{"rendered":"Struggling with ASP.NET MVC (2)"},"content":{"rendered":"<p>For a new project I&#8217;ve started, I decided to try out ASP.NET MVC. I consider my ASP.NET skills as good, so I assumed that would give me a head start with MVC. Not sure if it did though, thinking &#8216;old&#8217; ASP.NET based seems to be more of a challenge as opposed to really helping. <\/p>\n<p>A couple of my findings:<br \/>\n&#8211; Everything plays really nice as long as you play by the book. The minute you want something other then what the examples out there show, it&#8217;s a bit of a burden to get there.<br \/>\n&#8211; With ASP.NET you can get away without too much knowledge of JavaScript and things like jQuery and JSON. I noticed a lot of custom work in MVC is done with those techniques. I know a fair bit of JS, but not so much jQuery. Back to the books I guess \ud83d\ude42<br \/>\n&#8211; The availability of 3rd party components is more limited. And the components out there also seem to be limited when you compare them to the ASP.NET (AJAX) range. Take a look at what <a href=\"http:\/\/www.telerik.com\">Telerik<\/a> offers for instance.<br \/>\n&#8211; In the comparison with standard ASP.NET, MVC requires more code. That should deliver you a much cleaner project with more ability to do automated testing. It also provides you the possibility to make a big mess. The examples for ASP.NET are mostly in one line when covering things like databinding. The MVC examples aren&#8217;t. Use view models, don&#8217;t use view models. Incorporate logic and EF models into the Models dir, use seperate projects. I found all sorts of blogposts about roughly the same topics which all show different things. Which should I follow? Aaaargh!<\/p>\n<p>All of this reminds me about my first steps in ASP.NET programming. Not exactly knowing which approach to take or how to solve non standard problems. But altough it&#8217;s tempting to switch back to the known and safe approach, I&#8217;m sticking with MVC for now, just because I know lot&#8217;s of nice stuff is being done in MVC for a while now. And yes; I know there&#8217;s a V3, but my hosting company doesn&#8217;t support that yet. Bummer.<\/p>\n<p>So please fill up the comments:<br \/>\n&#8211; What resources are should-reads on MVC?<br \/>\n&#8211; What&#8217;s your approach when building an MVC project? How do you setup your projects, where do you leave your logic, etc?<br \/>\n&#8211; What&#8217;s your opinion about using ASP.NET \/ MVC or perhaps Dynamic Data? Is it a good thing their all there, or should we stick to one or two?<\/p>\n<p>Once my projects&#8217; launched, I&#8217;ll post an update on my MVC findings.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>For a new project I&#8217;ve started, I decided to try out ASP.NET MVC. I consider my ASP.NET skills as good, so I assumed that would give me a head start with MVC. Not sure if it did though, thinking &#8216;old&#8217; ASP.NET based seems to be more of a challenge as opposed to really helping. A<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","jetpack_publicize_message":"","jetpack_is_tweetstorm":false,"jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[34],"tags":[],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p3KFR1-4l","_links":{"self":[{"href":"http:\/\/blog.repsaj.nl\/index.php\/wp-json\/wp\/v2\/posts\/269"}],"collection":[{"href":"http:\/\/blog.repsaj.nl\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.repsaj.nl\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.repsaj.nl\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.repsaj.nl\/index.php\/wp-json\/wp\/v2\/comments?post=269"}],"version-history":[{"count":0,"href":"http:\/\/blog.repsaj.nl\/index.php\/wp-json\/wp\/v2\/posts\/269\/revisions"}],"wp:attachment":[{"href":"http:\/\/blog.repsaj.nl\/index.php\/wp-json\/wp\/v2\/media?parent=269"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.repsaj.nl\/index.php\/wp-json\/wp\/v2\/categories?post=269"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.repsaj.nl\/index.php\/wp-json\/wp\/v2\/tags?post=269"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}