What is a token?
From USWDS:
Design tokens are a limited set of discrete options, just like a scale of musical notes is drawn from the spectrum of all possible frequencies. Or like the presets on a car radio — not every option, just a specific selection.
- A token is a set of name and value pairs.
- The names are the words we use in our design that make it easier to understand and apply those discrete options.
- For example, instead of describing our type using pixel sizes, we use t-shirt sizes, like
sm
,md
, andlg
. When describing colors, we use palettes based on their function, likeprimary-dark
orwarning-light.
- The value of the pair is set to a default, but it can be changed if needed.
Recommended Resources
- Check out the origin of design tokens in this article from Salesforce, Living Design System: An approach for delivering a consistent design cross-platform. Salesforce began using design tokens to address the challenges of scaling products and making them easier to change/alter for continuous iterations.
- For a more in-depth look at tokens and some cool infographics, read Invision’s Guide to Design Tokens.