Contribution Guidelines
Contributions are always welcome, no matter how large or small. Before contributing, please read the code of conduct.
Before starting contributing we recommend reading the following guides:
Collaboration
Issues assigning
For avoiding situations than two contributors started resolving the same issue, recommending:
- Make yourself assignee at issue, or, if you haven't rights for this, write a comment at the issue about you started making.
- Move issue to "In Progress" column at next board.
Development Chat
Feel free to discuss any problem at the #development channel on our Spectrum.
Developing
Setup
- Install Node.js >= 8 and yarn.
- Clone repo:
git clone git@github.com:react-figma/react-figma.git
- Go to directory:
cd react-figma
- Install dependencies:
yarn
Running examples
Running webpack at watch mode
- Change directory to example directory:
cd /examples/<example dir>
- Run webpack: "npm run webpack:watch"
Plugin adding
- Go to Figma dashboard (icon with four squares)
- Click
Plugins
- Click to plus icon beside
Development
title - Click
Click to choose a manifest.json file
button - Select
/examples/<example dir>/manifest.json
file
Plugin launching
- Open or create new document
- Select Plugins -> Developing ->
<plugin name>
at the menu
Running linting/tests
- TypeScript:
npm run tsc
- Jest:
npm run test
Before commit pre-commit hook will be launched. It runs prettier and linting/tests.
Pushing changes
- Check linting/tests
- Check that project is can be built
npm run build
- Make Pull Request with your changes.