Skip to content

Commit bbea008

Browse files
committed
Improve Contributing section of readme
1 parent 124fe5d commit bbea008

File tree

1 file changed

+8
-23
lines changed

1 file changed

+8
-23
lines changed

README.md

Lines changed: 8 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ This hook returns an object containing the boolean results of several media quer
9898
}
9999
```
100100

101-
What's that good for? Say you have a React component you only want to display on `md`-sized screens. Thow this into your JSX:
101+
What's that good for? Say you have a React component you only want to display on `md`-sized screens. Throw this into your JSX:
102102

103103
```jsx
104104
{breakpoint.md && <MyComponent />}
@@ -127,30 +127,15 @@ Have fun!
127127

128128
<h2 id="contributing">Contributing</h2>
129129

130-
If you'd like to contribute to this project (which would be awesome), here's how to set it up:
130+
If you'd like to contribute to this project (which would be awesome), the easiest way to set it up would be to install the [GitHub CLI](https://cli.github.com/) and the run the following:
131131

132-
1. [Fork this repository](https://docs.github.com/en/github/getting-started-with-github/fork-a-repo) to your own GitHub account.
133-
134-
2. Clone it to your device.
135-
136-
```sh
137-
git clone https://github.com/YOUR_USERNAME/use-window-width-breakpoints.git
138-
```
139-
140-
3. Add this repository as a remote, so you can pull upstream changes in the future with `git pull upstream master`.
141-
142-
```sh
143-
cd use-window-width-breakpoints
144-
git remote add upstream https://github.com/tywmick/use-window-width-breakpoints.git
145-
```
146-
147-
4. Install dependencies.
148-
149-
```sh
150-
npm install
151-
```
132+
```sh
133+
gh repo fork tywmick/use-window-width-breakpoints --clone=true
134+
cd use-window-width-breakpoints
135+
npm install
136+
```
152137

153-
Now, you can build the package with `npm run build`, build _and_ watch for changes with `npm run dev` (automatically rebuilding on each change in the source), and run the test suite with `npm run test`.
138+
Now, you can build the package with `npm run build`, build _and_ watch for changes with `npm run dev` (automatically rebuilding on each change in the source), run the test suite with `npm run test`, and create pull requests with [`gh pr create`](https://cli.github.com/manual/gh_pr_create).
154139

155140
After building the package, you can test it in another project on your machine by [adding the local path](https://docs.npmjs.com/files/package.json#local-paths) as a dependency (e.g., by running `npm install /path/to/local/use-window-width-breakpoints` in that other project).
156141

0 commit comments

Comments
 (0)