Umbraco

Umbraco Forms 8.6 release

Rune Strand
Written by Rune Strand

A new minor release of Umbraco Forms is out today. With version 8.6 you get more control and flexibility to choose how you render (and validate) Umbraco Forms in your frontend.

Umbraco Forms has always had a hard dependency on jQuery. This meant that if you wanted client-side validation and to make use of things like conditional fields, you were forced to add jQuery, jQuery Validate and jQuery unObtrusive. 

In the past, this was not a huge deal, as jQuery was ubiquitous across the web and relying on it was very commonplace. With the advent of many popular javascript frameworks, it made less and less sense to require jQuery.

What has changed?

Nothing! Well, almost 😉Umbraco Forms will still work the way it has done before. You can render your forms and if the jQuery dependencies are included, they will be used. This means that upgrading to Umbraco Forms 8.6 doesn’t require you to make any changes…Unless you want to! 

You now have the option of not including the jQuery dependencies. Naturally, we still need to have code managing the client-side validation. All you have to do is add the following to templates where Umbraco Forms is used:

Alternatively you can add the dependencies at the end of your page:

Using the RenderUmbracoFormDependencies method will automatically include the scripts you need which now ship with Umbraco Forms. So no need to download jQuery or add external CDN and keep track of whether you are using the correct jQuery version. 

Documentation on how to prepare your frontend for Umbraco Forms has been updated to reflect the changes in 8.6.

How is validation handled now?

Umbraco Forms has relied on jQuery Validation Unobtrusive which allows validating using data-val attributes. In 8.6 we now include aspnet-validate.js, adding unobtrusive functionality and a polyfill to ensure it works in older browsers.

The new dependencies are only ⅓ the size of the old ones. This means you’ll be serving approximately 100kb less for Umbraco Forms to work. That might not seem like a lot, and in some cases it is negligible, but it can be a useful reduction in payload depending on the website.

What should I do when upgrading?

That depends! As noted earlier, you don’t have to do anything. If you are only including the jQuery frameworks to support Umbraco Forms it might be worth looking into. If you rely on jQuery for other things, then it might make more sense to keep it.

Do I need to upgrade?

We always encourage you to stay on top of the upgrades as you will benefit from other bug fixes as well. This release does contain another fix that you might benefit from.

Get your hands on Forms 8.6

The latest version of Forms is available on Our.  

On Umbraco Cloud, Forms 8.6 is available as a minor upgrade for all existing sites using Umbraco Forms 8.x.

All new sites on Umbraco Cloud will be running the latest version of Umbraco Forms.