Skip to content

Commit 58546de

Browse files
Update README, separate out contributing docs (#1588)
1 parent 45049d0 commit 58546de

File tree

3 files changed

+120
-114
lines changed

3 files changed

+120
-114
lines changed

β€Ž.github/CONTRIBUTING.md

Lines changed: 113 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,118 @@ It is highly appreciated that you take the time to help improve 🌲 Evergreen.
44

55
Please see our [issue template](ISSUE_TEMPLATE.md) for issues specifically.
66

7+
## Contributing to Evergreen
8+
9+
### 🍴 Step 1. Fork this repository
10+
11+
In order to contribute to Evergreen, you need to fork this repo, and develop on your own local clone.
12+
13+
If you don't know how to do so, follow this [guide](https://help.github.com/en/github/getting-started-with-github/fork-a-repo)!
14+
15+
### πŸ“– Step 2. Get storybook up and running
16+
17+
First, move into your local cloned repository with the help of `cd`, after that install your `node_modules` with:
18+
19+
```
20+
$ yarn
21+
```
22+
23+
To actually start seeing the components you have to run React Storybook with the command:
24+
25+
```
26+
$ yarn dev
27+
```
28+
29+
Now go to `http://localhost:6006` in your browser.
30+
31+
### πŸ›  Step 3. Make your change
32+
33+
Now you can start developing! All of the components are under the `src` directory and associated code changes will automatically be reflected in StoryBook.
34+
35+
If necessary, we encourage you to update the documentation so Evergreen users will be aware of your new features/changes.
36+
37+
In order to run the documentation page locally, run these commands in your terminal:
38+
39+
```
40+
$ yarn build
41+
$ cd docs
42+
$ yarn install
43+
$ yarn dev
44+
```
45+
46+
Now you can visit `http://localhost:3000/` in your browser.
47+
48+
Documentation code is under the `docs` directory. A big portion of these docs are written in MDX, if you've never used MDX before, check out these [docs](https://mdxjs.com/getting-started).
49+
50+
### πŸ† Step 4. Making your pull request
51+
52+
Once you're done with making your changes, push everything to your local repository's branch.
53+
54+
From here, you can open up a pull request from your forked repository's branch into `segmentio/evergreen`'s `master` branch.
55+
56+
In your PR description, explain the changes you made, why you made them, how to test them, and anything that might be a point of interest.
57+
58+
Once you create your PR, it will be reviewed and hopefully merged quickly!
59+
60+
### πŸ₯‚ Step 5. Pat yourself on the back
61+
62+
Congrats, you're officially an Evergreen contributor!
63+
64+
## πŸ€“ Scripts explained
65+
66+
Inside the `package.json` there are a bunch of scripts that this repo uses
67+
to run the project in development and to build the project.
68+
69+
Below you can read a description of each script.
70+
71+
- `yarn dev`: Starts the development React Storybook.
72+
73+
- `yarn test`: Lints the JavaScript files using eslint and then runs the unit tests using jest.
74+
75+
- `yarn build`: Builds all of the JavaScript files using Babel.
76+
77+
- `yarn clean`: removes all untracked files (`git clean -Xdf`).
78+
79+
- `yarn release`: Releases new version of Evergreen (requires MFA via npm as a collaborator)
80+
81+
- `yarn create-package`: This command scaffolds a package with no specific boilerplate. It's useful for creating utilities.
82+
83+
For the following command:
84+
85+
```
86+
yarn create-package utils
87+
```
88+
89+
The following file tree will be generated:
90+
91+
```
92+
/src/utils
93+
β”œβ”€β”€ /src/
94+
└── index.js
95+
```
96+
97+
- `yarn create-package:components`: This command scaffolds a package with React component(s) boilerplate.
98+
99+
You can pass one or more components to this command.
100+
101+
For the following command:
102+
103+
```
104+
yarn create-package:components typography Text Heading
105+
```
106+
107+
The following file tree will be generated:
108+
109+
```
110+
/src/typography
111+
β”œβ”€β”€ /src/
112+
| │── Text.js
113+
| └── Heading.js
114+
β”œβ”€β”€ /stories/
115+
β”‚ └── index.stories.js
116+
└── index.js
117+
```
118+
7119
## Creating new components
8120

9121
Preferably we like to introduce new components by following these steps.
@@ -55,4 +167,4 @@ Finally submit a PR with your new feature or component.
55167

56168
## Celebrate! πŸŽ‰
57169

58-
We'll add you to the contributors section.
170+
Thank you for your contribution to Evergreen!

β€ŽREADME.md

Lines changed: 5 additions & 112 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@
2222
- [Documentation](https://evergreen.segment.com/)
2323
- [GitHub Discussions](https://github.com/segmentio/evergreen/discussions)
2424

25-
## Evergreen v5 to v6 Migration guide
25+
## Evergreen v7 Migration guide
2626

27-
Evergreen v5 to v6 [migration guide](https://evergreen.segment.com/introduction/v6-migration-guide)
27+
Evergreen v7 [migration guide](https://evergreen.segment.com/introduction/migrations)
2828

2929
## Install and use components
3030

@@ -65,122 +65,14 @@ Evergreen supports a robust theming layer out of the box. You can check out [the
6565

6666
Evergreen offers easy Server Side Rendering (SSR) and automatic hydration.
6767

68-
Evergreen bundles 2 CSS-in-JS solutions, from glamor and ui-box. To make it super easy to do server side rendering and hydration, Evergreen exposes a `extractStyles()` function that will do SSR for both at once.
68+
Evergreen bundles its own CSS-in-JS solution from [ui-box](https://github.com/segmentio/ui-box). To make it super easy to do server side rendering and hydration, Evergreen exposes a `extractStyles()` function.
6969

7070
- How to use it with Next.js in the [ssr-next example app](examples/ssr-next).
7171
- [How to use it with GatsbyJS](https://github.com/segmentio/evergreen/issues/154)
7272

7373
## Contributing to Evergreen
7474

75-
### 🍴 Step 1. Fork this repository
76-
77-
In order to contribute to Evergreen, you need to fork this repo, and develop on your own local clone.
78-
79-
If you don't know how to do so, follow this [guide](https://help.github.com/en/github/getting-started-with-github/fork-a-repo)!
80-
81-
### πŸ“– Step 2. Get storybook up and running
82-
83-
First, move into your local cloned repository with the help of `cd`, after that install your `node_modules` with:
84-
85-
```
86-
$ yarn
87-
```
88-
89-
To actually start seeing the components you have to run React Storybook with the command:
90-
91-
```
92-
$ yarn dev
93-
```
94-
95-
Now go to `http://localhost:6006` in your browser.
96-
97-
### πŸ›  Step 3. Make your change
98-
99-
Now you can start developing! All of the components are under the `src` directory and associated code changes will automatically be reflected in StoryBook.
100-
101-
If necessary, we encourage you to update the documentation so Evergreen users will be aware of your new features/changes.
102-
103-
In order to run the documentation page locally, run these commands in your terminal:
104-
105-
```
106-
$ yarn build
107-
$ cd docs
108-
$ yarn install
109-
$ yarn dev
110-
```
111-
112-
Now you can visit `http://localhost:3000/` in your browser.
113-
114-
Documentation code is under the `docs` directory. A big portion of these docs are written in MDX, if you've never used MDX before, check out these [docs](https://mdxjs.com/getting-started).
115-
116-
### πŸ† Step 4. Making your pull request
117-
118-
Once you're done with making your changes, push everything to your local repository's branch.
119-
120-
From here, you can open up a pull request from your forked repository's branch into `segmentio/evergreen`'s `master` branch.
121-
122-
In your PR description, explain the changes you made, why you made them, how to test them, and anything that might be a point of interest.
123-
124-
Once you create your PR, it will be reviewed and hopefully merged quickly!
125-
126-
### πŸ₯‚ Step 5. Pat yourself on the back
127-
128-
Congrats, you're officially an Evergreen contributor!
129-
130-
## πŸ€“ Scripts explained
131-
132-
Inside the `package.json` there are a bunch of scripts that this repo uses
133-
to run the project in development and to build the project.
134-
135-
Below you can read a description of each script.
136-
137-
- `yarn dev`: Starts the development React Storybook.
138-
139-
- `yarn test`: Lints the JavaScript files using XO and then runs the unit tests using AVA.
140-
141-
- `yarn build`: Builds all of the JavaScript files using Babel.
142-
143-
- `yarn clean`: removes all untracked files (`git clean -Xdf`).
144-
145-
- `yarn release`: Releases new version of Evergreen (requires MFA via npm as a collaborator)
146-
147-
- `yarn create-package`: This command scaffolds a package with no specific boilerplate. It's useful for creating utilities.
148-
149-
For the following command:
150-
151-
```
152-
yarn create-package utils
153-
```
154-
155-
The following file tree will be generated:
156-
157-
```
158-
/src/utils
159-
β”œβ”€β”€ /src/
160-
└── index.js
161-
```
162-
163-
- `yarn create-package:components`: This command scaffolds a package with React component(s) boilerplate.
164-
165-
You can pass one or more components to this command.
166-
167-
For the following command:
168-
169-
```
170-
yarn create-package:components typography Text Heading
171-
```
172-
173-
The following file tree will be generated:
174-
175-
```
176-
/src/typography
177-
β”œβ”€β”€ /src/
178-
| │── Text.js
179-
| └── Heading.js
180-
β”œβ”€β”€ /stories/
181-
β”‚ └── index.stories.js
182-
└── index.js
183-
```
75+
Please see [CONTRIBUTING.md](.github/CONTRIBUTING.md) for more information on how to contribute!
18476

18577
## πŸŽ‰ Contributors
18678

@@ -193,6 +85,7 @@ We will add you to the list if you make any meaningful contribution!
19385
- Colin Lohner
19486
- Allen Kleiner
19587
- Chris Chuck
88+
- Brandon Scott
19689
- ... many other on the Segment team and open-source contributors
19790

19891
This project is maintained by [Segment](https://segment.com/)

β€Žpackage.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
"Matt Shwery (https://mattshwery.com)",
99
"Colin Lohner (https://www.colinlohner.com)",
1010
"Allen Kleiner (http://allenk.me/)",
11-
"Chris Chuck (https://github.com/Chrischuck)"
11+
"Chris Chuck (https://github.com/Chrischuck)",
12+
"Brandon Scott (https://brandonscott.me)"
1213
],
1314
"keywords": [
1415
"evergreen",

0 commit comments

Comments
Β (0)