Back to Plugins

variables2css
Convert Figma Variables to CSS, Sass, Tailwind, Json, Javascript (Styled-Components), Less or Stylus
csstokensjavascripttailwindstyled componentsvariablescss variablesstylusexportsassstylesjsoncode-generators
Plugin Preview
About this plugin
Convert Figma design variables, including colors and numbers, into CSS, Sass, Tailwind, Stylus, Json, Less or Javascript (Styled-Components) variables to save time and ensure accuracy. Use it in Figma: Design and Development mode.
How to use it:
- Select your collection and now also choose specific modes within that collection.
- Choose your output language: CSS, Sass, Tailwind, Stylus, Json, Less, or Javascript (Styled-Components).
- Select your preferred conversion: Hex, RGB, or HSL for colors and PX or Rem for units.
- Include all themes if you've created themes in your collection, such as dark/light mode.
- Ignore aliases to export base values or use the root alias as the variable name instead of the semantic alias.
- Choose whether to add fallback for variables.
- Generate your variables
What's New:
- Saved export settings: Your last export settings are saved and automatically selected when you reopen the plugin.
- Font Weight Scope: When the variable is scoped exclusively by font weight, the number is now output without a unit.
- String Export: Now, you can also export your string variables easily.
- Mode Selection: You can now select not just a collection but also specific modes within that collection, giving you greater flexibility and control over your design exports.
- New Design: Enjoy a completely redesigned interface that enhances usability and streamlines your workflow.
Notice:
- RGB Output Update: We've updated the RGB format to the new CSS standard: use rgb(255 0 0) for opaque colors and rgb(255 0 0 / 0.5) for transparent colors.
- In the JSON export, the attribute previously known as "color" has been renamed to "value" within the color array objects. This change affects how colors are represented in the exported JSON. Please update your integrations accordingly.
Plugin Details
Version | 49 |
---|---|
Created | July 13, 2023 |
Last Updated | January 19, 2025 |
Category | Software development |
Creator | Kai-Uwe Hella |
Stats | 2593 installs, 255 likes |
Pricing | Free |
Technical Details
- API:1.0.0
- UI:ui.html
- main:code.js
- Editor Types:figma
- Allowed Domains:
- none
More Like This
Discover other plugins in the Software development category.