Skip to content

Commit 9c4234f

Browse files
authored
Merge pull request #5435 from JedWatson/alex/tidy-readme
Update README
2 parents 338a45f + 5aaf9df commit 9c4234f

File tree

1 file changed

+4
-38
lines changed

1 file changed

+4
-38
lines changed

README.md

Lines changed: 4 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ The Select control for [React](https://reactjs.org). Initially built for use in
99

1010
See [react-select.com](https://www.react-select.com) for live demos and comprehensive docs.
1111

12-
React Select is funded by [Thinkmill](https://www.thinkmill.com.au) and [Atlassian](https://atlaskit.atlassian.com). It represents a whole new approach to developing powerful React.js components that _just work_ out of the box, while being extremely customisable.
12+
`react-select` is funded by [Thinkmill](https://www.thinkmill.com.au) and [Atlassian](https://atlaskit.atlassian.com).
13+
We are an open source project that is continously supported by the community.
14+
15+
React Select helps you develop powerful select components that _just work_ out of the box, without stopping you from customising the parts that are important to you.
1316

1417
For the story behind this component, watch Jed's talk at React Conf 2019 - [building React Select](https://youtu.be/yS0jUnmBujE)
1518

@@ -37,43 +40,6 @@ yarn add react-select
3740

3841
Then use it in your app:
3942

40-
#### With React Component
41-
42-
```js
43-
import React from 'react';
44-
import Select from 'react-select';
45-
46-
const options = [
47-
{ value: 'chocolate', label: 'Chocolate' },
48-
{ value: 'strawberry', label: 'Strawberry' },
49-
{ value: 'vanilla', label: 'Vanilla' },
50-
];
51-
52-
class App extends React.Component {
53-
state = {
54-
selectedOption: null,
55-
};
56-
handleChange = (selectedOption) => {
57-
this.setState({ selectedOption }, () =>
58-
console.log(`Option selected:`, this.state.selectedOption)
59-
);
60-
};
61-
render() {
62-
const { selectedOption } = this.state;
63-
64-
return (
65-
<Select
66-
value={selectedOption}
67-
onChange={this.handleChange}
68-
options={options}
69-
/>
70-
);
71-
}
72-
}
73-
```
74-
75-
#### With React Hooks
76-
7743
```js
7844
import React, { useState } from 'react';
7945
import Select from 'react-select';

0 commit comments

Comments
 (0)