|
1 | 1 | # Contributing
|
2 | 2 |
|
3 |
| -Thank you for considering contributing to this package! Let's get you started. |
| 3 | +**Thank you for considering contributing to this package**! This small guide will help you get started. |
4 | 4 |
|
5 |
| -## 1. Fork & Clone |
| 5 | +## 🍽️ Fork + Clone |
6 | 6 |
|
7 |
| -- Make a fork of this repository |
8 |
| -- Navigate to your forked repository and copy the SSH url. Clone your fork locally: |
| 7 | +1. Make a fork of this repository |
| 8 | +2. Navigate to your forked repository and copy the SSH url. Clone your fork locally: |
9 | 9 |
|
10 | 10 | ```bash
|
11 | 11 | $ git clone [email protected]:{ YOUR_USERNAME }/rtk-query-loader.git
|
12 | 12 | $ cd rtk-query-loader
|
13 | 13 | ```
|
14 | 14 |
|
15 |
| -- Once cloned, you will see `origin` as your default remote, pointing to your personal forked repository. Add a remote named upstream pointing to the main rtk-query-loader: |
| 15 | +3. Once cloned, you will see `origin` as your default remote, pointing to your personal forked repository. Add a remote named upstream pointing to the main rtk-query-loader: |
16 | 16 |
|
17 | 17 | ```bash
|
18 | 18 | $ git remote add upstream [email protected]:ryfylke-react-as/rtk-query-loader.git
|
19 | 19 | $ git remote -v
|
20 | 20 | ```
|
21 | 21 |
|
22 |
| -## 2. Create a new branch |
| 22 | +## ➕ Create a new branch |
23 | 23 |
|
24 |
| -- First, make sure you have the latest changes: |
| 24 | +1. First, make sure you have the latest changes: |
25 | 25 |
|
26 | 26 | ```bash
|
27 | 27 | $ git pull upstream main
|
28 | 28 | ```
|
29 | 29 |
|
30 |
| -- Then create a new feature branch for your changes: |
| 30 | +2. Create a new feature branch for your changes: |
31 | 31 |
|
32 | 32 | ```bash
|
33 | 33 | $ git checkout -b { YOUR_BRANCH_NAME } main
|
34 | 34 | ```
|
35 | 35 |
|
36 |
| -## 3. Add changes |
| 36 | +## 👩💻 Add your changes |
37 | 37 |
|
38 | 38 | For now, try to following existing patterns. Formalized code-guidelines will come at some point.
|
39 | 39 |
|
40 |
| -## 4. Test you changes |
| 40 | +If you have any questions, feel free to open up an issue! |
41 | 41 |
|
42 |
| -- First, make sure you create a link between your local package and the testing-app. In the root of the repository: |
| 42 | +## 🩺 Test you changes |
43 | 43 |
|
44 |
| -```bash |
45 |
| -$ yarn run setup-link |
46 |
| -``` |
47 |
| -
|
48 |
| -> If this doesn't work, try to run the commands manually: |
49 |
| -> |
50 |
| -> ```bash |
51 |
| -> $ npm link |
52 |
| -> $ cd testing-app |
53 |
| -> $ npm link @ryfylke-react/rtk-query-loader |
54 |
| -> ``` |
55 |
| -
|
56 |
| -- In the `testing-app` directory, install dependencies, and then run the tests: |
| 44 | +1. In the `testing-app` directory, install the project dependencies, and then run the tests: |
57 | 45 |
|
58 | 46 | ```bash
|
59 | 47 | $ yarn install
|
60 | 48 | $ yarn run test
|
61 | 49 | ```
|
62 | 50 |
|
63 |
| -- If you are adding a new feature, make sure to write a new test for your change in `testing-app/tests.test.tsx`. |
| 51 | +2. If you are adding a new feature, make sure to write a new test for your change in `testing-app/tests.test.tsx` and rerun. |
64 | 52 |
|
65 |
| -## 5. Commit & Push |
66 |
| -
|
67 |
| -- Commit your changes and push |
| 53 | +## 🤜 Push your changes |
| 54 | +If all the tests pass, you can commit your final changes and push! |
68 | 55 |
|
69 | 56 | ```bash
|
70 | 57 | $ git commit -a -m "feat: withLoader now has a new argument, ..."
|
71 | 58 | $ git push origin { YOUR_BRANCH_NAME }
|
72 | 59 | ```
|
73 | 60 |
|
74 |
| -- We prefer it if you try to stick to [conventional commit messages](https://www.conventionalcommits.org/en/v1.0.0/#summary). |
| 61 | +> We prefer it if you try to stick to [conventional commit messages](https://www.conventionalcommits.org/en/v1.0.0/#summary). |
75 | 62 |
|
76 |
| -## 6. Create pull-request |
| 63 | +## 📄 Create a pull-request |
77 | 64 |
|
78 |
| -- In Github, navigate to [@ryfylke-react/rtk-query-loader](https://github.com/ryfylke-react-as/rtk-query-loader) and click the button that reads "Compare & pull request". |
| 65 | +- On Github, navigate to [@ryfylke-react/rtk-query-loader](https://github.com/ryfylke-react-as/rtk-query-loader) and click the button that reads "Compare & pull request". |
79 | 66 | - Write a title and description, and submit your pull request.
|
| 67 | +
|
| 68 | +Your code will be reviewed and if everything looks good you'll be added to the list of contributors. |
| 69 | +
|
| 70 | +Any contribution is appreciated 🤘 |
0 commit comments