Skip to content

Latest commit

 

History

History
88 lines (59 loc) · 2.77 KB

CONTRIBUTING.md

File metadata and controls

88 lines (59 loc) · 2.77 KB

Contributing

To get started with this project, follow these steps.

Preparation

To get started, clone the project and install the required dependencies. This project relies on the yarn package manager. Additionally this is a monorepo that depends on yarn workspaces and lerna to manage multiple packages

git clone [email protected]:gr4vy/embed.git
cd embed
# npm i -g yarn
yarn config set workspaces-experimental true
yarn setup

Development Server

To run the local development server for all projects run the following command at the root of the project.

yarn dev

This will open a development preview of Gr4vy Embed and the React component.

Note: By default yarn dev will open on http://localhost:8081/ yet you will not see anything. The reason for this is that this page expects the Embed UI to be running on http://localhost:8080/. Please see the Embed UI project for more details.

Local testing and linting

Tests and linting are provided by a mix of jest, eslint and prettier.

yarn lint
yarn test

Note: We try to keep a coverage of a 100%. Run the yarn test command to see more details on our current coverage level. Missed lines can be explored by opening the coverage/index.html file after a test has been run.

Releasing a PR

Raising a PR against the main branch will trigger Github actions. In order to produce a meaninful changelog, we use Auto https://intuit.github.io/auto/ to manage versioning and change logs. This allows us to edit the PR directly before merging.

PR Titles

Auto will use the PR title as the message in the change log. This means it needs to be human readable and meaningful. Try to avoid using ticket numbers or meta information - instead describe the value the change brings.

Release notes

PR titles are limited in character length and you may need to provide more details. You can add a ## Release Notes section for this. Only this section will appear in the Change Log, not the entire body of the PR.

## Release Notes

Write additional notes here...

Labels

Labels inform what type of change has occured so that the correct semver number can be assigned for the release.

The following labels will increment the version number:

  • major - 💥 Breaking Change (major)
  • minor - 🚀 Enhancement (minor)
  • patch - 🐛 Bug Fix (patch)
  • performance - 🏎 Performance (patch)

The following labels will have no effect on the version:

  • internal - 🏠 Internal (no version)
  • documentation - 📝 Documentation (no version)
  • test- 🧪 Tests (no version)
  • dependencies - 🔩 Dependency Updates (no version)

Finally, to trigger a release you must include the release label:

  • release - Create a release when PR is merged