Figma is free to use. Sign up here:
By definition, a variable is something that can vary in value or take on multiple values. Variables in Figma store reusable values, like color values and numbers, that can be applied to all kinds of design properties and even prototypes! A variable’s values can also reference other variables, making updating design systems a breeze. In this video, we’ll cover how variables work, and how to use them to represent design tokens and account for different modes and themes.
* Update: When following along with the tutorial at 10:30, the variable called “.5“ will no longer work. This is due to our alignment with the W3C spec which doesn’t allow periods in names. Calling the variable “spacing/half“ will work, instead.
We are doing a follow-up in the next coming months where we’ll be separating out the “figma name” from the code syntax, which may let us loosen these restrictions. Keep an eye out for additional syntax support in the future.
Follow along with the file:
Learn about prototyping with variables with our other tutorial:
Learn more about variables in Figma with our additional playground file:
Learn more about design systems in Figma:
Help center articles:
Guide to variables:
Overview of variables:
Create and manage variables:
Apply variables to designs:
Modes for variables:
For more information on using variables with API and development, check out the links here:
- REST API: #variables
- Plugin API docs:
- Import/export variables code sample
- Styles to variables convert code sample
Chapters:
00:00 - Intro
01:17 - Color variables
03:55 - Create tokens
06:00 - Apply variables
07:13 - Styles vs variables
08:17 - Modes
10:12 - Number variables
12:35 - Themes
14:11 - Wrap up
____________________________________________________
Find us on ⬇️
Twitter:
Instagram:
LinkedIn:
Figma forum:
____________________________________________________
#Figma #Config #Config2023 #Variables #Designtokens #Tutorial #design #tips #DesignSystems