Skip to content

Theming

Learn how to create and customise a theme.

Create a theme

Creating your first theme is as simple as calling the createTheme function. It's ready to go out-of-the-box with the default theme. The next few sections will show you how to customise the theme to match your brand.

Customise a theme

Themes are built on a set of core tokens or Foundations. These tokens correspond to raw values, such as a font size or hex value.

Our approach to theming is to set default values and then allow you to override the theme.

Themes are combined with a deep merge. This will update any dynamic tokens. When you add custom theme values you should also provide the typings.

It is also possible to extend the theme, adding your own variables.

CSS Reset

You will need to import the css reset in order for the theme to display components correctly. It will adjust the font size of the page to make it easier to work with rems. Rem Units in CSS (opens in new window)