Skip to content

Commit cb0ca7a

Browse files
authored
Merge pull request #118 from springload/chore/create-contributing-doc
Shift the development-related stuff out of README and into CONTRIBUTING
2 parents b0f48df + ef93c8b commit cb0ca7a

File tree

2 files changed

+62
-60
lines changed

2 files changed

+62
-60
lines changed

CONTRIBUTING.md

+53
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# Contributing
2+
3+
## Development
4+
5+
### Install
6+
7+
> Clone the project on your computer, and install [Node](https://nodejs.org). This project also uses [nvm](https://github.com/springload/frontend-starter-kit/blob/master/docs/useful-tooling.md#nvm).
8+
9+
```sh
10+
nvm install
11+
# Then, install all project dependencies.
12+
npm install
13+
# Install the git hooks.
14+
./.githooks/deploy
15+
# Set up a `.env` file with the appropriate secrets.
16+
touch .env
17+
```
18+
19+
### Working on the project
20+
21+
> Everything mentioned in the installation process should already be done.
22+
23+
```sh
24+
# Make sure you use the right node version.
25+
nvm use
26+
# Start the the development tools in watch mode.
27+
npm run start
28+
# Runs linting.
29+
npm run lint
30+
# Runs tests.
31+
npm run test
32+
# View other available commands with:
33+
npm run
34+
```
35+
36+
### Run the demo
37+
38+
> Everything mentioned in the installation process should already be done.
39+
40+
```sh
41+
# Make sure you use the right node version.
42+
nvm use
43+
# Start the server and the development tools.
44+
npm run start-demo
45+
```
46+
47+
### Publish
48+
49+
```sh
50+
npm version [TYPE]
51+
git push origin master --tags
52+
npm publish
53+
```

README.md

+9-60
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ ReactDOM.render(<Example />, document.querySelector('[data-mount]'));
5858
### Styles
5959

6060
We strongly encourage you to write your own styles for your accordions, but we've published these two starter stylesheets to help you get up and running:
61+
6162
```js
6263
// 'Minimal' theme - hide/show the AccordionBody component:
6364
import 'react-accessible-accordion/dist/minimal-example.css';
@@ -229,73 +230,21 @@ This project manages two types of Accordions, with single or multiple items open
229230
230231
For this type of Accordion, you will get the following `role` set up on your elements:
231232

232-
* Accordion: `tablist`
233-
* AccordionItem: no specific role
234-
* AccordionItemTitle: `tab`
235-
* AccordionItemBody: `tabpanel`
233+
* Accordion: `tablist`
234+
* AccordionItem: no specific role
235+
* AccordionItemTitle: `tab`
236+
* AccordionItemBody: `tabpanel`
236237

237238
#### Multiple items
238239

239240
For this type of Accordion, you will get the following `role` set up on your elements:
240241

241242
> Use this with with props `accordion` set to `false` on `Accordion`.
242243
243-
* Accordion: no specific role
244-
* AccordionItem: no specific role
245-
* AccordionItemTitle: `button`
246-
* AccordionItemBody: no specific role
247-
248-
## Development
249-
250-
### Install
251-
252-
> Clone the project on your computer, and install [Node](https://nodejs.org). This project also uses [nvm](https://github.com/springload/frontend-starter-kit/blob/master/docs/useful-tooling.md#nvm).
253-
254-
```sh
255-
nvm install
256-
# Then, install all project dependencies.
257-
npm install
258-
# Install the git hooks.
259-
./.githooks/deploy
260-
# Set up a `.env` file with the appropriate secrets.
261-
touch .env
262-
```
263-
264-
### Working on the project
265-
266-
> Everything mentioned in the installation process should already be done.
267-
268-
```sh
269-
# Make sure you use the right node version.
270-
nvm use
271-
# Start the the development tools in watch mode.
272-
npm run start
273-
# Runs linting.
274-
npm run lint
275-
# Runs tests.
276-
npm run test
277-
# View other available commands with:
278-
npm run
279-
```
280-
281-
### Run the demo
282-
283-
> Everything mentioned in the installation process should already be done.
284-
285-
```sh
286-
# Make sure you use the right node version.
287-
nvm use
288-
# Start the server and the development tools.
289-
npm run start-demo
290-
```
291-
292-
### Publish
293-
294-
```sh
295-
npm version [TYPE]
296-
git push origin master --tags
297-
npm publish
298-
```
244+
* Accordion: no specific role
245+
* AccordionItem: no specific role
246+
* AccordionItemTitle: `button`
247+
* AccordionItemBody: no specific role
299248

300249
# Browser support
301250

0 commit comments

Comments
 (0)