New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

figma-export-variables

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

figma-export-variables

Export figma variables with puppeteer

  • 0.2.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

figma-export-variables

Command line for export variables

How it works?

This script is designed to kickstart the browser, navigating through Figma's interface to extract variables. Its primary goal is to duplicate a file and retrieve the collection from the replica. Post-extraction, whether successful or not, the duplicated file undergoes deletion. A Figma login is imperative. In case it's the first login via Puppeteer, the script may launch the browser with a graphical user interface, streamlining the manual login process into Figma.

Install

While you can install it globally on your machine, it's much better to install it locally project by project.

npm install --save-dev figma-export-variables
figma-export-variables --help

Note: If you do not have a package.json, create one before installing or run npm init -y to automatically create ones.

Usage

npx figma-export-variables COMMAND

Commands

interactive

By default, the browser runs without a graphical user interface (GUI). In case of any issues, you have the option to run it with a GUI.

npx figma-export-variables --interactive

use-config

You must create a configuration file and use a single command to rule them all :ring:

Let's create the file .figmaexportvariablestrc.js and paste the following:

module.exports = {
    commands: [
        ['variables', {
            fileId: 'SOME_UNIQ_ID',
            outputters: [output]
        }]
    ]
};

:information_source: Take a look at .figmaexportvariablestrc.js.example for more details.

now you can update the package.json.

{
  "scripts": {
+   "figma-variables:export": "figma-export-variables use-config"
  }
}

If needed you can also provide a different configuration file.

{
  "scripts": {
+   "figma-variables:export": "figma-export-variables use-config .figmaexportrc.production.js"
  }
}

Keywords

FAQs

Package last updated on 17 Jan 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc