Building custom themes for Sitecore Webforms for Marketers (WFFM) can be a painful and messy exercise. Your stylesheets get bloated, your selectors are too specific and you need to use overriding styles or !important properties. All of this just makes the whole process feel really messy and code quickly becomes unwieldy.

To help solve this problem I decided to create a Webforms for Marketers boilerplate. This blog gives a quick overview of what the boilerplate includes and how it helped me build custom themes for WFFM quickly and consistently.

A Little Bit of Background

Over the past few years I’ve always had some sort of styling task with Webforms for Marketers which used to be time consuming and would gradually become difficult to manage as the project grew.

To try and tackle this problem I blogged about how to Improve Webforms for Marketers styling using Grunt. The aim of that blog post was to help Sitecore Front-End developers with some of the problems faced over the years working with Webforms for Marketers; I hope this helped someone out there.

Recently I’ve been working on a project which required custom work to be done on WFFM and refactoring due to mid-project change requests and a colleague of mine had broken out some of the preprocessor files into partials to try and help with code maintenance, which is great!.

This made me stop and think… “The amount of times I’ve had to do the same task over and over again styling Webforms for Marketers… There must be a better way!?”.

With this in mind I decided to spend some time in the evenings and write a no-frills boilerplate for Webforms for Marketers to try and reduce setup time, copying files and overriding madness.

Building the Webforms for Marketers Boilerplate

When deciding to create this project I had a few goals in mind:-

  1. Quick and easy setup
  2. Each form property should have its own responsibility
  3. Clean slate (no unnecessary code)
  4. Minimal effort to understand
  5. Increase productivity

I set up a Sitecore Webforms for Marketers Helper repository on GitHub to share with the Sitecore community (this is my first community bit of work – be nice =) ) and should have everything you need to get styling Webforms for Marketers with ease.

I will try and support this repository as best I can and if there’s anything I may have missed please feel free to add an issue.

If you like the look of this repository or it helped you in any way it would be greatly appreciated if you clicked that star button.

Thanks for reading; happy coding!

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s