Development Dive into Craft CMS

A fresh developer’s take on Craft CMS

Putting together the pieces together…

The ever-changing landscape of the web is an inevitable fact of life. It can be overwhelming for a new developer coming from almost a decade teaching high school math (a landscape that hardly changes, but probably should). Now this can either be a good thing or a bad thing. For any pessimist out there, it seems that once you start to figure something out, everything changes. If you identify as an optimist (like I do), you might say that everyone has a level playing field when it comes to the next big thing.

A well-worn path: WordPress and the way it’s been done

To be clear, there is a reason why WordPress owns a large share of the market. It works. It’s used by both small and large companies alike. There’s a large community around WordPress, and it’s a road many have travelled on. That’s not to say it’s the only route on a website’s journey.

At Standard Beagle, a user experience design and development agency in Austin, we are interested in shifting some of our developing practices to use Craft CMS. There are many flavors of CMS out there, and the most popular by many measures is WordPress. Since 2003, WordPress has grown and mutated from being blog-focused to what it is today; a CMS powering anywhere between 32.5% and 39.6% of all websites on the internet today [1]. It’s undeniably a great way to build websites, and I’m sure we’ll continue to use WordPress if the client/project is the perfect fit. But each project is a snowflake, a one-of-a-kind idea that deserves a tailored approach.

A look into the origins of Craft

Craft was developed by Pixel and Tonic out of Bend, Oregon. They began working on the project in 2011, and released the first version in 2013. Two years later it won the Best CMS for Developers award by CMSCritics. With any decision regarding web development, there is no “one-size-fits-all”, and each project is unique and deserves time and consideration when in development. Some projects might be best suited for WordPress, others maybe better served with Craft, or Strapi, Contentful, or the hundreds of others. For the purpose of this article, I’m going to be focusing on Craft, and how it compares on some levels to WordPress.

Fresh flexible and fast

In WordPress, the look and feel of your site comes from the theme that is enabled. There are many starter themes to choose from, and you can develop your own custom themes to suit your needs. With Craft, there are no starting themes; instead you start with a blank sheet of paper every time. This can be good or bad. I know times when I was glad to have features baked into a project from the start. Other times, I had to fight myself to understand why the theme was acting a certain way. With Craft, you won’t have to worry about some functionality embedded in a theme that could bog down your site, because there won’t be any code that you didn’t put there yourself. This pushes Craft developers to be experts in their craft (ugh, sorry).

Without unnecessary code that you might get in a pre-packaged theme, sites built with Craft can have much faster loading times. This will give users a better experience on your site and improve your SEO score with Google. Faster loading times play a direct role in customer engagement, with some studies showing that a load time longer than three seconds on a mobile the page will lose around 53% of users [2].

Craft is the new kid in town, the baby face of the bunch, and that lets Craft be flexible. The older anything is, the more rigid it can become. WordPress was built to host blogs, and they assume you will have posts on your page. Craft doesn’t assume anything, and instead let’s you set whichever custom fields are needed for the site. Developers have more flexibility to tailor entry types for the data a site will use, and that will also help clients who are managing and updating content.

Craft and the JAMstack

One thing I’m most excited about exploring is using Craft as a headless CMS. With this option, craft can be paired with a static version of your website, following principles of the JAMstack. On the front end, you could use a static site framework like Gatsby or Next.js. The concept of a headless CMS is a different approach for serving web pages and data. This approach separates what the user sees (the “head”) from the content management side of the website that only authors and admins can view. A restaurant has two sides; the dining area for customers and the kitchen for waitstaff and cooks. To extend the metaphor, a headless CMS is a catering company, where they prepare the food in one location and then can deliver the food anywhere it’s requested.

“For Craft specifically, to go headless basically means foregoing Craft’s template rendering capabilities entirely, and instead serving CMS content as structured data over a web API.” [3]

As I dive deeper into Craft, I will continue to write about my experiences through the eyes of a fresh-faced developer, what I perceive to be pros and cons, and hopefully some insight for anyone else expanding their CMS offerings.