What does a Craft CMS developer need to know

As a Craft developer, there are different areas you need to be skilled in for successful web projects.

HTML/CSS/Tailwind

In a Craft project, you are undoubtedly going to come across HTML and CSS. HTML (Hypertext Markup Language) is on every website and is the basic framework all websites are built on. In its most rudimentary terms, a p tag will allow you to show a paragraph. An img tag will display an image. There are around 100 tags you need to know about and be able to utilise.

CSS (Cascading Style Sheets) works closely alongside HTML and lets you style elements. For instance, you would add a border to an image using border: 3px solid white.

Both HTML and CSS evolve and introduce new features regularly, so it’s not a case of resting on your laurels.

Whilst HTML and CSS have been around for decades, many sites use Tailwind to make CSS authoring easier. It works by using minimal CSS, yet HTML tags power the styling. I am quite new to Tailwind, but after using it on a recent project, I was surprised by how much affection I have grown for it. I held off using it for many years because I didn't like the idea of muddying the HTML, but if you have experience with CSS, I highly recommend using it on a project or two, since it's widely used on millions of websites now. The learning curve isn't particularly high, as at its core it’s CSS powering it. The adoption of Tailwind in the last few years has been impressive, and having it under your belt as a skill can only benefit you. I recommend learning CSS first, though, because that's really what it is when you break it down.

Command line

The command line is now an important part of building Craft CMS sites. If you cannot use the command line efficiently, then you will struggle to build a Craft site; it's that simple. Many of the tasks you do with the command line are very similar. If using DDEV, navigate to your Craft project folder and run ddev start. DDEV does all the heavy lifting, and you can then load your project in your browser or something to someone like project-name.ddev.site. Whilst daunting initially, the learning curve for the command line isn't steep. As a Craft CMS developer, you are doing very similar things on most of your projects. Plugins can be managed in the user interface via your Craft admin, but I highly recommend installing and uninstalling them via the command line. It's cleaner and just a better way of controlling your plugins. You will also update your Craft sites using Composer, and again, that’s best done on the command line. The command line is a doddle really, but you need to build some Craft sites and get used to it.

Web hosting

As Craft CMS is self-hosted, you naturally need to know a good bit about web hosting to get a Craft site up and running. I personally use DigitalOcean Droplets managed via Laravel Forge. Whilst I'm competent with the command line, Forge makes server maintenance incredibly easy with an intuitive UI that covers everything you need to do, including .env files and your nginx configs. SSL certificates (secure certificates) can be installed in a click, and Laravel Forge makes things so much easier for you. Sure, you should skip this tool and use the command line, but some things are better done in a UI, and Forge is a good decision.

Plugins a bonus

Plugins are a big part of Craft CMS; they extend the core Craft CMS code to do much more powerful things. That said, I don't write more than the most basic of plugins. You don't need to on the majority of builds. If a client comes to Media Surgery asking for sole plugin development, I put them into more capable hands, Craft developers who specialise in writing plugins, such as Josh Crawford, whom I interviewed here last year. I have a good understanding of how most major plugins work, but I don't write them myself. If you are a Craft developer who can also write substantial plugins, then that's a bonus.

Twig

The wonderful Twig powers all Craft sites. It’s an easy-to-use yet deceptively powerful templating language. Twig is one option for using Craft on its own. Sure, there is a bit of a learning curve, but it's well worth getting really deep into utilising it. Twig integrates well with HTML, and you will often run through loops in Twig and output HTML elements like unordered lists and nested divs. Developers outside of Craft write Twig, and it powers other CMSes too. The makers of Craft, Pixel and Tonic, do regularly contribute to the Twig library, enhancing it even further.

In summary of what a Craft CMS developer needs to know

Craft developers need a range of skills to build good sites. Sure, there is a learning curve. If you want to build better websites, the advice I always remember is to build more websites. Every site you build is better than the last.

Written by John Macpherson

Categories: