|
| 1 | +# Contributing |
| 2 | + |
| 3 | +## Contributing to this repo |
| 4 | + |
| 5 | +This repository is managed by EasyCLA. Project participants must sign the free |
| 6 | +[GraphQL Specification Membership agreement](https://preview-spec-membership.graphql.org) |
| 7 | +before making a contribution. You only need to do this one time, and it can be |
| 8 | +signed by |
| 9 | +[individual contributors](https://individual-spec-membership.graphql.org) or |
| 10 | +their [employers](https://corporate-spec-membership.graphql.org). |
| 11 | + |
| 12 | +To initiate the signature process please open a PR against this repo. The |
| 13 | +EasyCLA bot will block the merge if we still need a membership agreement from |
| 14 | +you. |
| 15 | + |
| 16 | +You can find |
| 17 | +[detailed information here](https://github.com/graphql/graphql-wg/tree/main/membership). |
| 18 | +If you have issues, please email |
| 19 | +[operations@graphql.org](mailto:operations@graphql.org). |
| 20 | + |
| 21 | +If your company benefits from GraphQL and you would like to provide essential |
| 22 | +financial support for the systems and people that power our community, please |
| 23 | +also consider membership in the |
| 24 | +[GraphQL Foundation](https://foundation.graphql.org/join). |
| 25 | + |
| 26 | +## Running a new build |
| 27 | + |
| 28 | +- Install the latest version of Node and NPM |
| 29 | +- Install the Node dependencies with `npm install` |
| 30 | +- Build a new spec with `npm run build` |
| 31 | + - This will output the new spec text in `/public` as HTML files |
| 32 | + |
| 33 | +## Contributing to the spec text |
| 34 | + |
| 35 | +### Auto-Formatting |
| 36 | + |
| 37 | +The specification is formatted using the `prettier` tool, so you should not need |
| 38 | +to think about gaps between paragraphs and titles, nor about word wrapping - |
| 39 | +this is handled for you. |
| 40 | + |
| 41 | +### Adding spec examples |
| 42 | + |
| 43 | +To keep things consistent in the spec, we should use examples that reference an |
| 44 | +e-commerce store. We should use types like `Product`, `User`, `Review`, etc. |
| 45 | + |
| 46 | +### Adding new sections |
| 47 | + |
| 48 | +Sections in the spec document are nested under top level sections, then topic |
| 49 | +sections, then specific sections. We should aim to limit to 3 nested levels and |
| 50 | +consider flattening once we reach 4 levels. |
0 commit comments