File tree 2 files changed +23
-2
lines changed
2 files changed +23
-2
lines changed Original file line number Diff line number Diff line change @@ -104,7 +104,7 @@ Also possible to change the current value using `value` property
104
104
const { value } = this .props ;
105
105
…
106
106
< Select2
107
- value= { value }
107
+ value= { value }
108
108
data= {[
109
109
{ text: ' bug' , id: 1 },
110
110
{ text: ' feature' , id: 2 },
@@ -117,6 +117,27 @@ const { value } = this.props;
117
117
/ >
118
118
```
119
119
120
+ ### Option Groups
121
+
122
+ ``` js
123
+ < Select2
124
+ multiple
125
+ data= {[
126
+ { text: ' Development' ,
127
+ children: [
128
+ { text: ' bug' , id: 1 },
129
+ { text: ' feature' , id: 2 },
130
+ ],
131
+ },
132
+ { text: ' documents' , id: 3 },
133
+ { text: ' discussion' , id: 4 },
134
+ ]}
135
+ options= {{
136
+ placeholder: ' search by tags' ,
137
+ }}
138
+ / >
139
+ ```
140
+
120
141
### Properties
121
142
122
143
You can pass any properties such as ` class ` , ` id ` , ` data-* ` attributes
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " react-select2-wrapper" ,
3
- "version" : " 0.4 .0" ,
3
+ "version" : " 0.5 .0" ,
4
4
"description" : " React component for Select2" ,
5
5
"main" : " lib/components/Select2.js" ,
6
6
"scripts" : {
You can’t perform that action at this time.
0 commit comments