what are you looking for?

JONDJONES.COM
  • Books
    BOOKS
    • Umbraco ASP.NET 5 Mastery
    • Umbraco V8 Secrets Exposed
    • Episerver Missing Manual
  • CMS
    Umbraco
    • V9 Tutorials
    • V8 Tutorials
    • V7 Tutorials
    • Ultimate Umbraco Guide
    Episerver
    • Tutorials By Published Date
    • Tutorials By Category
    • Ultimate Episerver Guide
    • BOOK: Episerver: The Missing Manual
    Sitecore
    • Sitecore Tutorials
  • React & JS
    React JS
    • Tutorials By Published Date
    • Tutorials By Category
    • Ultimate React Guide
    Javascript
    • Tutorials By Published Date
    • Tutorials By Category
    • CODE: #ILoveJavascript
  • Architecture
  • Tactics
    Productivity
    • Productivity Tutorials
    • Ultimate Productivity Guide
    Insights
    • Blog
  • YouTube
  • About
  • Hire Me
    My Services
    • Umbraco Freelancer
    • Episerver Freelancer
    • JAMStack Freelancer
    My Qualifications
    • My Portfolio
    • LinkedIn Profile
    • Stackoverflow CV
    My Company & Experience
    • Digital Prompt
  • Contact

Strongly Typed Models Within Umbraco

  • Homepage
  • Learn Umbraco CMS
  • Umbraco 7 Tutorials
  • Strongly Typed Models Within Umbraco
How To Get Started With Umbraco ModelsBuilder
How To Get Started With Umbraco ModelsBuilder
Fri 20 July, 2018
Using Umbraco.ModelsBuilder.API To Create Strongly Typed Models Within Umbraco
Using Umbraco.ModelsBuilder.API To Create Strongly Typed Models Within Umbraco
Sun 9 September, 2018
How To Use The Umbraco ModelsBuilder In Different Class Libraries Using AppData Mode
How To Use The Umbraco ModelsBuilder In Different Class Libraries Using AppData Mode
Mon 17 September, 2018
How To Use UmbracoMapper To Implement Strongly Typed Models in Umbraco 7
How To Use UmbracoMapper To Implement Strongly Typed Models in Umbraco 7
Thu 26 November, 2015
How To Get An IPublishedContent from a Uid In Umbraco
How To Get An IPublishedContent from a Uid In Umbraco
Tue 4 December, 2018
Strongly Typed Models Within Umbraco

MVC stands for model, view, controller.  The idea behind this pattern is to separate your different concerns, to make testing and managing your website easier.  Historically, when developers have worked with Umbraco they have broken this paradigm.  If you have been passing in the IPublishedContent and then wiring up your properties within your views, you have in effect been muddling your HTML with your code.

A better approach is to pass in a strongly-typed C# model into your views.  All the code and logic required to get the data needed to render page data on your page should be done in the controller level - or at a minimum - the model level.  You should avoid doing logic in your views.  Even though it is possible to do this, you are in effect breaking the MVC pattern.  One of the reasons MVC was adopted, is to make maintaining your website easier.  Every time you break the MVC approach, you will make your website that much harder to test and maintain later on.

In this section, you will learn everything you need in order for you to use MVC correctly in your website by following the correct principles of MVC

UMBRACO ASP.NET 5 MASTERY
Umbraco V8 Secrets Exposed
NAVIGATION
  • Umbraco Getting Started Advice
  • Umbraco Core Concepts
  • Umbraco API Explained
  • How To Structure Your Umbraco Project
  • Umbraco and MVC
  • Creating Your First Umbraco Page
  • Strongly Typed Models Within Umbraco
  • Grid Editor
  • Umbraco Component Tutorials
  • Umbraco Caching
  • Umbraco Backend Customisation
  • Umbraco Deployment
  • Umbraco Event Handling
  • Umbraco Hosting
  • Umbraco Load Balancing
  • Umbraco Multi-Language
  • Umbraco Plugins
  • Umbraco Performance Tweaking
  • Umbraco Routing
  • Umbraco Search
  • Umbraco Security
  • Umbraco SEO
  • Umbraco Tips And Advice
  • Umbraco Troubleshooting
  • Umbraco Unit Testing
  • Umbraco Upgrading Guide
  • Umbraco Web API
  • Wordpress Content Into Umbraco
  • uSiteBuilder
UMBRACO V8 BOOK
Umbraco V8 Secrets Exposed

I 💖 Umbraco

New to Umbraco CMS and want to learn how to get started?

Ultimate Umbraco Guide

✉️ WEEKLY ✉️
DEVELOPER TIPS
Get a weekly links to cool and interesting stuff, code snippets, project ideas, tools and tips.

Thank you!

You have successfully joined our subscriber list.

SUPPORT MY WORK



SUPPORT THIS SITE

Click An Advert

WELCOME

Hi,, I'm Jon, I write articles about creating and optimizing websites to help your business meet its goals. I am a technical architect and technology fanatic by profession. You can find out more about me by joining my newsletter.

Latest Posts
  • 20 Amazing Productivity Tools For Windows Programmers
  • Umbraco 9 Models Builder Deep Dive
  • Dependency Injection Deep Dive Within Umbraco V9
  • 12 Amazing Visual Studio 2022 Extensions That Will Boost Your Productivity

© Jon D Jones