2025-06-17

⚜️ Design systems

Introduction to design systems, style guides, and component libraries.

A design system is a broader term usually consisting of a few sub-systems. Most people have their own definitions, but there are a common distinguish between a style guide and a component library.

When creating a style guide, you usually take a broader approach, including branding, typography, colors, and components.

In contrast, a component library is often focused on the components themselves.


What is a component library?

A component library gives developers and designers a mutual ground to look at when discussing form and function.

It is a collection of code that documents UI patterns for a web-based project. It start with the smallest possible components and build up to larger page modules.

Example of naming when talking about component libraries


Design System generators

Fractal

We have used Fractal on a few projects lately and are very happy with that. There is a Twig version so we can use it for production ready components.

KSS (Twig)

For smaller projects, a generator like kss-node is a good choice. The concept is to use comments in the CSS to generate a style guide.

It can support Twig and are, therefore, a good match to use with Craft CMS, but the implementation is more or less system agnostic. We have used it with Statamic, and in other scenarios, too.

Other well-known alternatives that we haven’t tried (yet):

Or, a simpler alternative:



Resources