Marathon Celebrates 15 Year Anniversary
April 01, 2021
Umbraco 8 – What’s New and Should I Upgrade?
What is Umbraco?
Umbraco is a content management system (CMS) with a focus on ease of use, user experience, flexibility, and support. Umbraco is built on Microsoft .NET and uses the MVC model for development. Umbraco has been in existence for over 15 years and has a solid base of packages and support from the development community.
What is Umbraco 8?
Umbraco 7 has been very successful since its release in 2013, and saw widespread adoption and praise. As time went on, small edits and API changes began to pile up, and the codebase began to get messy. There were multiple ways to do things, and supporting these different methods and API calls was beginning to become unwieldy. The Umbraco team also received valuable feedback on the backoffice user flow and recognized the importance of multilingual support in a modern CMS.
Umbraco 8 was designed to solve these problems. Umbraco 8's main purpose is to clean up the codebase and standardize API calls. As a side effect, speed improvements may also be realized, as Umbraco 8 has a much lighter codebase. Umbraco 7 was recognized as a fantastic CMS, and Umbraco 8 was designed to further refine the backoffice experience and provide several new features.
Umbraco 8 offers three major new features over Umbraco 7:
- Infinite Editing
- Language Variants
- Content Apps
Infinite editing describes a new backoffice workflow in which backoffice settings such as document types, settings, media, and content can be edited infinitely from the same browser window. For example, instead of having to open a new window or tab to make changes to document type property and its associated data types, you never have to leave the window. Your management actions will cascade over multiple popup windows effortlessly, saving you the time of manipulating multiple browser windows. These stacked windows also behave more intelligently, expanding wider for certain content instead of always remaining the same width.
Language variants is a new feature which provides various versions of content. Each node can have multiple variants, one for each language, and these variants can be pulled based on the requested language. Instead of relying on third party packages, this support is now baked into the core.
Content Apps refers to a new way of enhancing backend experiences with relevant feedback. Content Apps are not meant to directly take part in the user’s editing experience, but instead are intended to provide information, statistics, or suggestions for content while the editor is editing their content.
For example, instead of a hard-coded info tab for each content node which displays url and history information, Umbraco 8 utilizes its own “Info” Content App, which provides all of this information as a content app. This concept can be utilized by developers going forward, so that integration with third party apps & services can be made and utilized. For example, it is possible to add a Content App which displays a google map populated with relevant information, or analytics pulled in from another datasource which further enhances the editor’s understanding of their content. For a demo, check out Preflight.
A New Umbraco 8 Feature is Coming: Block Editor
A new upcoming back-office editor for Umbraco 8, Block Editor, promises to redefine the back-office editing experience in a simple and straightforward way. This is a project which is now entering development, and will only be available for Umbraco 8. The block editor will be an alternative to the grid editor, and will not rely on third party packages such as DocTypeGridEditor or LeBlender to provide an intuitive editing experience. The idea is to focus on ease of use and simplicity over functionality, but according to the latest RFC, the functionality will be sufficient for nearly any page layout. One can read the details on the RFC Page. This new editor will not be released for some time, but it will make Umbraco 8 even more attractive as a CMS option.
Code Changes / Breaking Changes
There are several changes to Umbraco 8 which developers need to be aware of. These changes include:
- IPublishedContent models no longer offer the GetPropertyValue method, instead you can access them Model.Value<type>(“FieldAliasHere”). Alternatively, you may utilize a builder mode which allows you to easily access a generated class (ex. LiveDll) via Content.FieldAliasHere.
- Rendering Grids has changed slightly, from @Html.GetGridHtml(Model.Content, fieldAliasHere), to @Html.GetGridHtml(Model, fieldAliasHere)
- Nested Content returns IEnumerable<IPublishedElement> instead of the classic IEnumerable<IPublishedContent>.
- Examine Search API calls are completely different.
- Umbraco event management and hooks have changed, events are now defined inside of Components and the components are added to the Composition object on application start. This should make for improved organization, but is different compared to how things used to be.
- Logging has switched from Log4Net to Serilog, will log as json now.
- The popular package LeBlender, which allows for easily creating grid editors, is not officially supported in Umbraco 8, although there is an unofficial version. This means one must either use a similar supported package such as DocTypeGridEditor, go through the trouble of creating grid editors manually, or wait for the Block Editor project.
What Hasn’t Changed That Much
These remain largely as they were in Umbraco 7:
- The MVC programming model and its concepts
- Document Types, Data Types
- Grid Editors
- Media Types
- The IContentService / IMediaService are still used, although the calls have changed slightly
- Views are still stored in the /Views folder
Today Umbraco 8 offers an official content migration path from Umbraco 7.14+. This means that it is easier to migrate a site’s content from Umbraco 7 to 8. Previously, one of the only ways of upgrading content involved utilizing USync and exporting content, modifying the exported xml files to match Umbraco 8’s USync content, and then importing them into Umbraco 8. Now that Umbraco 7.14+ databases can be directly upgraded to Umbraco 8 databases, the content migration process should be more straightforward.
An issue of great importance when considering upgrading is that you need to be aware of what packages do not exist in Umbraco 8. Always make sure that your target CMS has the capabilities and packages that your website requires. If upgrading, content migration is only one part of the process - you will also need to update your codebase to use Umbraco 8 API calls instead of the Umbraco 7 ones.
Do I Need To Upgrade My Existing Umbraco 7 Site?
The answer to this question differs based upon what you want and need. Umbraco 7 will continue to have security and critical bug fixes released until September 30th, 2023, so support for Umbraco 7 isn’t going away any time soon. Does your Umbraco 7 site work well? Are you happy with it? Does having new Umbraco features other than security updates not really matter to you? If so, you probably should not upgrade at this time.
If you want to take advantage of the latest Umbraco features and packages, then you should consider upgrading to Umbraco 8. However, you should be aware that Umbraco 8 may not currently support the packages that you have been using in Umbraco 7, so you will need to see if Umbraco 8 supports your needs (ex. LeBlender isn’t officially supported in Umbraco 8).
What About New Sites, Should They Be Built in Umbraco 8?
The question should be, what packages do you need and are those supported in Umbraco 8? As Umbraco 8 matures, more and more packages will be available, but many packages are not yet available in Umbraco 8. Also, minor packages with small adoption may never get official Umbraco 8 support.
Are there packages that you are attached to that aren’t supported in Umbraco 8 yet? Perhaps you should think twice about creating your new site in Umbraco 8. Will your new site utilize packages and features that exist in Umbraco 8? Then you should consider using Umbraco 8 to build your next site.
Umbraco 8 is a well-built evolution of the Umbraco CMS, and offers valuable new features. It's is a great choice for a CMS, but before diving in, you should spend a few minutes to see if the packages that you need are supported. Umbraco 8 continues to impress with its new feature set, and we can’t wait to see what is coming next!