LA So Cal Code Camp

Last weekend I fortunate enough to attend SoCal Code Camp Los Angeles. It was an awesome event and lots of fun.Thanks to all who attended my presentations. I would appreciate any feedback you might have. Please leave comments at http://speakerrate.com/hattan

Here are the slides and code samples.

    • Getting Started with ASP.NET MVC
      Download the Powerpoint slides.
      Download the
      Sample Project
    • ASP.NET MVC 2 Best Practices
    • Download the Powerpoint slides.
      Download the ToDoList.Bad projectThis is an example of poorly created mvc application. Some of the problems with it:

      • Data Access Code (linq 2 sql in this case) is placed in the controller instead of a business layer.
      • Action method extracts value from Request.Form instead of action method input parameters.
      • Validation is in the controller and is repeated across multiple actions via copy paste.
      • Controller creates html as a string. (Violates the mvc pattern)
      • PRG (Post-Redirect-Get) pattern not used. After a post, a user clicking refresh can cause data to be modified again!
      • Code Duplication via copy paste. Violates DRY (don’t repeat yourself) principle.

      Download the ToDoList project
      Here’s the same project but built using a good separation of concerns and unit testing.

    • Download the Sample Project
      Download the Telerik Sample
      For instructions on setting up a new project with the Telerik extensions for mvc, see this post.

    • What’s New in ASP.NET MVC3
      Download the Powerpoint slides.
    • Download the Sample Project

Advertisements