This is Figma widget that contains a basic, best-practice checklist for design system component development. Loosely based on Nathan Curtis’ Figma Component Review article: https://medium.com/eightshapes-llc/the-figma-component-review-f42114450b4d
When placed on the Figma canvas near a component, the idea is that the checklist items help ensure the component is properly structured and robust enough for use in a design system setting.
Below are the steps to get your widget running. You can also find instructions at:
https://www.figma.com/widget-docs/setup-guide/
This widget template uses Typescript and NPM, two standard tools in creating JavaScript applications.
First, download Node.js which comes with NPM. This will allow you to install TypeScript and other libraries. You can find the download link here:
https://nodejs.org/en/download/
Next, install TypeScript and the latest type definitions by running:
npm install
If you are familiar with JavaScript, TypeScript will look very familiar. In fact, valid JavaScript code is already valid Typescript code.
TypeScript adds type annotations to variables. This allows code editors such as Visual Studio Code to provide information about the Figma API while you are writing code, as well as help catch bugs you previously didn't notice.
For more information, visit https://www.typescriptlang.org/
Using TypeScript requires a compiler to convert TypeScript (code.ts) into JavaScript (code.js) for the browser to run.
We recommend writing TypeScript code using Visual Studio code:
- Download Visual Studio Code if you haven't already: https://code.visualstudio.com/.
- Open this directory in Visual Studio Code.
- Compile TypeScript to JavaScript: Run the "Terminal > Run Build Task..." menu item, then select "tsc: watch - tsconfig.json". You will have to do this again every time you reopen Visual Studio Code.
That's it! Visual Studio Code will regenerate the JavaScript file every time you save.