If you’ve been in the frontend dev community for a while you have probably heard of a little thing called Atomic Design. Atomic Design is a methodology that involves breaking a website layout down into its basic components, which are then reused throughout the site .
There are many benefits to using Atomic Design.
9 important reasons you should use Atomic design
- You can mix and match components
By breaking down components into basic atoms it’s easy to see what parts of the site can be reused. And how they can be mixed and matched to form other molecules and even organisms.
Let’s say a site only contains five atoms: a small image, large image, paragraph, list item, and a link. You could create a very usable web page by duplicating and combining these atoms to make molecules.
- Creating a style guide is simple
If a site is created according to Atomic Design principles from the get-go. All the atoms and molecules that are created before the site is built can serve as a basic style guide. Even for sites that haven’t been built atomically. It isn’t difficult to extrapolate the basic components and put them together to construct more pages. Bear in mind, though, it is always best to create a site atomically from the beginning, rather than trying to introduce Atomic Design principles to a site later on.
- Easy to understand layout
The code of an atomically designed website is typically much easier to read than one created a more traditional way. This is true not only during the time of creation, but in the future when a site is being looked back on for reference or small tweaks. Because of the documentation around what atoms molecules and organisms are being used and where, it’s easy to see what each part of the code represents. Another bonus of this is that it makes it easier to explain the codebase to a new developer.
- Code is more consistent
With Atomic Design, you use predefined atoms to create the site layout, it is easy to see which components are being used for different parts of the site. This reduces the likelihood of writing duplicate code.
For example, if someone creates a site without using Atomic Design and they require, say, a red button, they would have to look through the whole site to try and find an existing one. If this did exist, they would need to copy and paste that code to the new instance. If there were no red buttons, they’d need to create a new one. With Atomic Design however, it is easy to go back through the list of atoms and find that exact red button.
- No focus on pixel-perfect designs
As the idea behind Atomic Design is to use atoms as the building blocks for site creation. It is less likely that a web developer will create many atoms for a similar thing. Instead, they can simply look through the list of existing atoms, and tweak them to create new atoms if required.
- Quicker prototyping
Having a list of atoms before site creation begins means you can mock up pages quickly and easily – all that is required is to pick and combine the required elements for the page. The mockup can then be customized and refined for the final site.
- Easier to update and remove parts of the site
As only one atom, molecule or organism is being changed at any one time, it is easy to ensure that any updates to a component are carried across to all other instances across the site. Similarly, unwanted components can easily be removed.
- More modular file structure
Although Atomic Design is very prevalent when it comes to markup (HTML). I believe these techniques can also be used for CSS, JavaScript, or any other languages. That is used to create a site to make overall code more modular and reusable.
- Fewer components overall
If a creator has a list of atoms, molecules and organisms presented to them before site creation begins. They are more likely to use what already exists than create new components for small variations. If a title font size of 4.5em is required for a design but there is already a 4em size title in existence from the list of atoms. It is more likely a creator will pick the 4em one than create a completely new title. This will result in fewer atoms being used overall, making for a cleaner and leaner website.