Skip to content

Latest commit

 

History

History
74 lines (55 loc) · 2.5 KB

CONTRIBUTING.md

File metadata and controls

74 lines (55 loc) · 2.5 KB

Contributing to React Stripe.js

Thanks for contributing to React Stripe.js!

Issues

React Stripe is a thin wrapper around Stripe.js and Stripe Elements for React. Please only file issues here that you believe represent bugs with React Stripe.js, not Stripe.js itself.

If you're having general trouble with Stripe.js or your Stripe integration, please reach out to us using the form at https://support.stripe.com/email or come chat with us on the Stripe Discord server. We're very proud of our level of service, and we're more than happy to help you out with your integration.

If you've found a bug in React Stripe.js, please let us know! You may also want to check out our issue template.

API review

At Stripe, we scrutinize changes that affect the developer API more so than implementation changes. If your code change involves adding, removing, or modifying the surface area of the API, we ask that you go through an API review by following this guide. It's best to go through API review before implementing a feature. If you've already implemented a feature, address the API review considerations within your pull request.

Going through an API review is not required, but it helps us to understand the problem you are trying to solve, and enables us to collaborate and solve it together.

Code review

All pull requests will be reviewed by someone from Stripe before merging. At Stripe, we believe that code review is for explaining and having a discussion around code. For those new to code review, we strongly recommend this video on "code review culture."

Developing

Install dependencies:

yarn install

Run the examples using Storybook:

yarn storybook

We use a number of automated checks:

  • Flow, for adding types to JavaScript
    • yarn run flow
  • Jest, for testing
    • yarn test
  • ESLint, for assorted warnings
    • yarn run lint
  • Prettier, for code formatting
    • yarn run prettier

You might want to configure your editor to automatically run these checks. Not passing any of these checks will cause the CI build to fail.